uga-rosa/ccc.nvim

Specify disable trailing_whitespace condition by funcion

ogaken-1 opened this issue · 2 comments

Request for additional color space

I want to configure like below.

local ccc = require('ccc')
ccc.setup {
  pickers = {
    ccc.picker.trailing_whitespace {
      enable = true,
      disable = function(bufnr)
        return not vim.bo[bufnr].buftype == ''
      end,
    }
  }
}

Currently, we can specify a list of filetypes to disable, but in most of my use cases I wanted to disable when &buftype !=# ''.
(like terminal, gitcommit, help, mason, fzf etc...)

Request for other features

No response

Please try PR 87

It seem works. Thank you!