-
-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix(conform.nvim): code format via conform.nvim (#272)
* chore(install): disable nvim-lint generated configs * chore(hooks): narrow hooks file * chore(hooks): narrow hooks file * chore(hooks): narrow hooks files * chore(hooks): narrow ignored generated hooks * chore(hooks): narrow ignored generated files * fix(mason-null-ls.nvim): ensure diagnostics installed, not formatters * fix(mason-null-ls.nvim): disable formatters setup handlers * chore(neoconf): format code * fix(conform.nvim): use conform formatter on <leader>cf * fix(conform.nvim): fallback to lsp * fix(conform.nvim): fix vim commands
- Loading branch information
1 parent
f56dada
commit a0c1848
Showing
10 changed files
with
88 additions
and
74 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
local keymap = require("builtin.utils.keymap") | ||
|
||
local M = { | ||
keymap.set_lazy_key( | ||
{ "n", "x" }, | ||
"<Leader>cf", | ||
"<cmd>lua require('conform').format({ timeout_ms = 2000, lsp_fallback = true })<cr>", | ||
{ desc = "Code format" } | ||
), | ||
} | ||
|
||
return M |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,29 +1,26 @@ | ||
// Please copy this file to 'neoconf.json' to enable it. | ||
{ | ||
"neodev": { | ||
"library": { | ||
"enabled": true, | ||
"plugins": [ | ||
"nvim-lspconfig", | ||
"lsp" | ||
] | ||
} | ||
}, | ||
"neoconf": { | ||
"plugins": { | ||
"lua_ls": { | ||
"enabled": true | ||
} | ||
} | ||
"neodev": { | ||
"library": { | ||
"enabled": true, | ||
"plugins": ["nvim-lspconfig", "lsp"] | ||
} | ||
}, | ||
"neoconf": { | ||
"plugins": { | ||
"lua_ls": { | ||
"enabled": true | ||
} | ||
} | ||
}, | ||
"lspconfig": { | ||
"lua_ls": { | ||
"Lua.format.enable": false, // use stylua formatter | ||
"Lua.completion.callSnippet": "Replace", | ||
"Lua.workspace.checkThirdParty": false | ||
}, | ||
"lspconfig": { | ||
"lua_ls": { | ||
"Lua.format.enable": false, // use stylua formatter | ||
"Lua.completion.callSnippet": "Replace", | ||
"Lua.workspace.checkThirdParty": false | ||
}, | ||
"jsonls": { | ||
"json.format.enable": false // use prettier formatter | ||
} | ||
"jsonls": { | ||
"json.format.enable": false // use prettier formatter | ||
} | ||
} | ||
} |