Skip to content

Commit

Permalink
neogit: update aus, fix buffer local options by deferring
Browse files Browse the repository at this point in the history
  • Loading branch information
ttytm committed Jun 3, 2024
1 parent fadcf80 commit fbb92b4
Showing 1 changed file with 8 additions and 5 deletions.
13 changes: 8 additions & 5 deletions lua/nxvim/plugins/neogit.lua
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,14 @@ local config = {

-- { == Events ==> ===========================================================

nx.au({ "FileType", pattern = "NeogitCommitMessage", command = "setlocal spell" })
nx.au({
"Filetype",
pattern = "NeogitCommitMessage",
callback = function()
vim.defer_fn(function() vim.o.spell = true end, 100)
end,
})
-- { "Filetype", pattern = "NeogitCommitMessage", command = "setlocal spell et ts=2 sw=2" },
-- <== }

-- { == Keymaps ==> ==========================================================
Expand All @@ -34,10 +41,6 @@ config.mappings = {
}

nx.map({ "<leader>gn", "<Cmd>Neogit<CR>", desc = "Neogit" })
nx.au({
{ "Filetype", pattern = "NeogitPushPopup", command = "nnoremap <buffer> F <nop>" },
{ "Filetype", pattern = "NeogitCommitMessage", command = "setlocal et ts=2 sw=2" },
})
-- <== }

-- { == Highlights ==> =======================================================
Expand Down

0 comments on commit fbb92b4

Please sign in to comment.