summaryrefslogtreecommitdiffstats
path: root/TOOLS/lua/autoload.lua
diff options
context:
space:
mode:
Diffstat (limited to 'TOOLS/lua/autoload.lua')
-rw-r--r--TOOLS/lua/autoload.lua4
1 files changed, 3 insertions, 1 deletions
diff --git a/TOOLS/lua/autoload.lua b/TOOLS/lua/autoload.lua
index 10c7fbdef0..aa7e46d060 100644
--- a/TOOLS/lua/autoload.lua
+++ b/TOOLS/lua/autoload.lua
@@ -157,7 +157,9 @@ function find_and_add_entries()
return
end
table.filter(files, function (v, k)
- if (o.ignore_hidden and string.match(v, "^%.")) then
+ -- The current file could be a hidden file, ignoring it doesn't load other
+ -- files from the current directory.
+ if (o.ignore_hidden and not (v == filename) and string.match(v, "^%.")) then
return false
end
local ext = get_extension(v)