aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
-rw-r--r--.config/nvim/after/ftplugin/gitcommit.lua3
-rw-r--r--.config/nvim/lua/vimrc/plugins.lua9
2 files changed, 10 insertions, 2 deletions
diff --git a/.config/nvim/after/ftplugin/gitcommit.lua b/.config/nvim/after/ftplugin/gitcommit.lua
new file mode 100644
index 0000000..b7662fa
--- /dev/null
+++ b/.config/nvim/after/ftplugin/gitcommit.lua
@@ -0,0 +1,3 @@
+vimrc.after_ftplugin('gitcommit', function(conf)
+ vim.o.spell = true
+end)
diff --git a/.config/nvim/lua/vimrc/plugins.lua b/.config/nvim/lua/vimrc/plugins.lua
index 395cc58..217f21c 100644
--- a/.config/nvim/lua/vimrc/plugins.lua
+++ b/.config/nvim/lua/vimrc/plugins.lua
@@ -507,9 +507,14 @@ return {
{
'rhysd/committia.vim',
config = function()
+ -- Disable 'spell' option, which is inherited from gitcommit buffer.
+ -- See also: ../../after/ftplugin/gitcommit.lua
vim.g.committia_hooks = {
- edit_open = function(_info)
- vim.wo.spell = true
+ diff_open = function(_info)
+ vim.o.spell = false
+ end,
+ status_open = function(_info)
+ vim.o.spell = false
end,
}
end,