summaryrefslogtreecommitdiffstats
path: root/plugin
diff options
context:
space:
mode:
authorThomas Vanbesien <tvanbesi@proton.me>2026-06-24 17:46:43 +0200
committerThomas Vanbesien <tvanbesi@proton.me>2026-06-24 17:46:43 +0200
commit3f586600ba1b2c61490a76b654e23228bdeaeee9 (patch)
treea7e5defb4a462e722441a844712005eb4c820b30 /plugin
parent7b355d982c23e566c9761bfb64e012d9c11d9072 (diff)
downloadnvim-config-3f586600ba1b2c61490a76b654e23228bdeaeee9.tar.gz
nvim-config-3f586600ba1b2c61490a76b654e23228bdeaeee9.zip
fix(nvim): source local config after all other plugins
Diffstat (limited to 'plugin')
-rw-r--r--plugin/50-local.lua8
-rw-r--r--plugin/99-local.lua11
2 files changed, 11 insertions, 8 deletions
diff --git a/plugin/50-local.lua b/plugin/50-local.lua
deleted file mode 100644
index 88c63c5..0000000
--- a/plugin/50-local.lua
+++ /dev/null
@@ -1,8 +0,0 @@
---
--- local include plugin
---
-
-local local_config_file = vim.fn.stdpath("config") .. "/local.lua"
-if vim.uv.fs_stat(local_config_file) then
- dofile(local_config_file)
-end
diff --git a/plugin/99-local.lua b/plugin/99-local.lua
new file mode 100644
index 0000000..c1eb8f6
--- /dev/null
+++ b/plugin/99-local.lua
@@ -0,0 +1,11 @@
+--
+-- 99-local.lua
+--
+-- * Sources `local.lua` from the config directory if it exists (machine-local overrides, untracked).
+-- Numbered 99 so it loads after every other plugin file — overrides only stick if they run last.
+--
+
+local local_config = vim.fs.joinpath(vim.fn.stdpath("config"), "local.lua")
+if vim.uv.fs_stat(local_config) then
+ dofile(local_config)
+end