moved to stow

This commit is contained in:
Belal Elsabbagh
2024-12-23 10:51:37 +02:00
parent ee043ddeec
commit 8b6f7c4467
73 changed files with 60 additions and 110 deletions

View File

@@ -0,0 +1,50 @@
return {
'stevearc/conform.nvim',
event = { 'BufWritePre' },
cmd = { 'ConformInfo' },
keys = {
{
'<leader>cf',
function()
require('conform').format { async = true, lsp_format = 'fallback' }
end,
mode = '',
desc = '[C]ode [F]ormat',
},
},
opts = {
notify_on_error = true,
format_on_save = {
-- These options will be passed to conform.format()
timeout_ms = 1000,
},
formatters_by_ft = {
lua = { 'stylua' },
go = { 'gofmt' },
python = { 'ruff' },
javascript = { 'biome', 'prettier', stop_after_first = true },
typescript = { 'biome', 'prettier', stop_after_first = true },
yaml = { 'prettier' },
rust = { 'rustfmt', lsp_format = 'fallback' },
json = { 'biome', 'prettier', stop_after_first = true },
vue = { 'biome', 'prettier' },
php = { 'pint', 'intelephense', stop_after_first = true },
},
formatters = {
biome = {
meta = {
url = 'https://github.com/biomejs/biome',
description = 'A toolchain for web projects, aimed to provide functionalities to maintain them.',
},
command = 'biome',
stdin = true,
args = { 'format', '--stdin-file-path', '$FILENAME' },
},
intelephense = {
command = 'intelephense',
args = {},
},
},
},
}