aboutsummaryrefslogtreecommitdiff
path: root/runtime/lua/vim/_watch.lua
diff options
context:
space:
mode:
Diffstat (limited to 'runtime/lua/vim/_watch.lua')
-rw-r--r--runtime/lua/vim/_watch.lua6
1 files changed, 6 insertions, 0 deletions
diff --git a/runtime/lua/vim/_watch.lua b/runtime/lua/vim/_watch.lua
index 97c5481ad1..23c810099e 100644
--- a/runtime/lua/vim/_watch.lua
+++ b/runtime/lua/vim/_watch.lua
@@ -290,6 +290,10 @@ function M.fswatch(path, opts, callback)
if data and #vim.trim(data) > 0 then
vim.schedule(function()
+ if vim.fn.has('linux') == 1 and vim.startswith(data, 'Event queue overflow') then
+ data = 'inotify(7) limit reached, see :h fswatch-limitations for more info.'
+ end
+
vim.notify('fswatch: ' .. data, vim.log.levels.ERROR)
end)
end
@@ -303,6 +307,8 @@ function M.fswatch(path, opts, callback)
fswatch_output_handler(line, opts, callback)
end
end,
+ -- --latency is locale dependent but tostring() isn't and will always have '.' as decimal point.
+ env = { LC_NUMERIC = 'C' },
})
return function()