mirror of
https://github.com/neovim/neovim.git
synced 2026-04-17 13:03:03 +00:00
fix(difftool): ensure standardized locale for diff output parsing #38853
Always pass LC_ALL=C to diff when parsing its output. Closes #38838 Signed-off-by: Tomas Slusny <slusnucky@gmail.com>
This commit is contained in:
@@ -117,7 +117,9 @@ local function diff_dirs_diffr(left_dir, right_dir, opt)
|
||||
table.insert(args, left_dir)
|
||||
table.insert(args, right_dir)
|
||||
|
||||
local lines = vim.fn.systemlist(args)
|
||||
-- Force English locale so that we can rely on the output format
|
||||
local result = vim.system(args, { text = true, env = { LC_ALL = 'C' } }):wait()
|
||||
local lines = vim.split(result.stdout or '', '\n', { trimempty = true })
|
||||
local qf_entries = {}
|
||||
|
||||
for _, line in ipairs(lines) do
|
||||
|
||||
Reference in New Issue
Block a user