aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorzeertzjq <zeertzjq@outlook.com>2023-03-18 09:55:08 +0800
committerGitHub <noreply@github.com>2023-03-18 09:55:08 +0800
commitc6f8af36e134a67b489d59e078425cada5eafd7b (patch)
tree9229610ebc4d3eeb58deab9037f472f53697a5d1 /src
parenteb3fcf652bbcab01cd6d55a0e2c120c09cbe69d3 (diff)
downloadrneovim-c6f8af36e134a67b489d59e078425cada5eafd7b.tar.gz
rneovim-c6f8af36e134a67b489d59e078425cada5eafd7b.tar.bz2
rneovim-c6f8af36e134a67b489d59e078425cada5eafd7b.zip
fix(spell): properly source spell/LANG.{vim,lua} (#22716)
Using regexp doesn't work here because there are no wildcards.
Diffstat (limited to 'src')
-rw-r--r--src/nvim/optionstr.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/nvim/optionstr.c b/src/nvim/optionstr.c
index 40cddebc2e..218b34472a 100644
--- a/src/nvim/optionstr.c
+++ b/src/nvim/optionstr.c
@@ -1578,7 +1578,9 @@ static void do_spelllang_source(win_T *win)
}
}
if (p > q) {
- vim_snprintf(fname, sizeof(fname), "spell/%.*s.\\(vim\\|lua\\)", (int)(p - q), q);
+ vim_snprintf(fname, sizeof(fname), "spell/%.*s.vim", (int)(p - q), q);
+ source_runtime(fname, DIP_ALL);
+ vim_snprintf(fname, sizeof(fname), "spell/%.*s.lua", (int)(p - q), q);
source_runtime(fname, DIP_ALL);
}
}