mirror of
https://github.com/m-housh/dotfiles.git
synced 2026-02-14 14:12:41 +00:00
feat: Reworking nvim configuration
This commit is contained in:
@@ -1,7 +1,19 @@
|
||||
return {
|
||||
"mhartington/formatter.nvim",
|
||||
event = { "BufReadPre", "BufNewFile" },
|
||||
config = function()
|
||||
keys = {
|
||||
{
|
||||
"<leader>f",
|
||||
":Format",
|
||||
desc = "[F]ormat",
|
||||
},
|
||||
{
|
||||
"<leader>F",
|
||||
":FormatWrite",
|
||||
desc = "[F]ormat write",
|
||||
},
|
||||
},
|
||||
config = function(_, opts)
|
||||
local util = require("formatter.util")
|
||||
require("formatter").setup({
|
||||
filetype = {
|
||||
@@ -50,13 +62,6 @@ return {
|
||||
},
|
||||
})
|
||||
|
||||
-- Keymaps
|
||||
local wk = require("which-key")
|
||||
wk.add({
|
||||
{ "<space>f", ":Format", desc = "[F]ormat" },
|
||||
{ "<space>F", ":FormateWrite", desc = "[F]ormat write" },
|
||||
}, { mode = "n", silent = true })
|
||||
|
||||
local augroup = vim.api.nvim_create_augroup
|
||||
local autocmd = vim.api.nvim_create_autocmd
|
||||
|
||||
|
||||
Reference in New Issue
Block a user