summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--init.lua10
1 files changed, 10 insertions, 0 deletions
diff --git a/init.lua b/init.lua
index db55a9e..667fb9c 100644
--- a/init.lua
+++ b/init.lua
@@ -600,6 +600,16 @@ require('lazy').setup({
{ -- Autoformat
'stevearc/conform.nvim',
+ keys = {
+ {
+ '<leader>f',
+ function()
+ require('conform').format { async = true, lsp_fallback = true }
+ end,
+ mode = '',
+ desc = '[F]ormat buffer',
+ },
+ },
opts = {
notify_on_error = false,
format_on_save = function(bufnr)