Compare commits

..

2 Commits

Author SHA1 Message Date
Christoph J. Scherr e1abfdead2 formatter updates, something for json 2024-12-02 23:25:31 +01:00
Christoph J. Scherr 1e52cce66f nothing 2024-12-02 23:25:23 +01:00
2 changed files with 11 additions and 2 deletions

View File

@ -54,7 +54,7 @@ vim.keymap.set('n', ']d', vim.diagnostic.goto_next, { desc = 'Go to next [D]iagn
-- let me out!!!
vim.keymap.set({ 'n', 'v' }, 'qqq', '<cmd>bnext<cr><cmd>bd #<cr>', { desc = '[Q]uit the current window' })
vim.keymap.set({ 'n', 'v' }, '<A-c>', '<cmd>bnext<cr><cmd>bc #<cr>', { desc = '[C]lose the current buffer' })
vim.keymap.set({ 'n', 'v' }, '<A-c>', '<cmd>bnext<cr><cmd>bd #<cr>', { desc = '[C]lose the current buffer' })
vim.keymap.set({ 'n' }, '#', "'", { desc = '[Q]uit the current window' })

View File

@ -31,14 +31,23 @@ return {
lsp_fallback = not disable_filetypes[vim.bo[bufnr].filetype],
}
end,
default_format_opts = {
lsp_format = 'fallback',
},
formatters_by_ft = {
fallback = { 'prettier' },
lua = { 'stylua' },
json = { { 'jq', 'biome', 'clang-format', 'prettier' } },
rust = 'rustfmt',
c = 'clang-format',
cpp = 'clang-format',
python = 'autopep8',
-- Conform can also run multiple formatters sequentially
-- python = { "isort", "black" },
--
-- You can use a sub-list to tell conform to run *until* a formatter
-- is found.
-- javascript = { { "prettierd", "prettier" } },
javascript = { { 'prettierd', 'prettier' } },
},
},
},