-
-
Notifications
You must be signed in to change notification settings - Fork 237
Closed
Labels
bugSomething isn't workingSomething isn't working
Description
Description
After updating to c3070fc, select_hunk
no longer works.
Neovim version
NVIM v0.10.2 Build type: Release LuaJIT 2.1.1713773202 Run "nvim -V1 -v" for more info
Operating system and version
NixOS 24.11
Expected behavior
Using a mapping that invokes select_hunk
should work, e.g., vih
should select the hunk.
Actual behavior
Nothing happens.
Minimal config
for name, url in pairs{
gitsigns = 'https://github.com/lewis6991/gitsigns.nvim',
-- ADD OTHER PLUGINS _NECESSARY_ TO REPRODUCE THE ISSUE
} do
local install_path = vim.fn.fnamemodify('gitsigns_issue/'..name, ':p')
if vim.fn.isdirectory(install_path) == 0 then
vim.fn.system { 'git', 'clone', '--depth=1', url, install_path }
end
vim.opt.runtimepath:append(install_path)
end
require('gitsigns').setup{
debug_mode = true, -- You must add this to enable debug messages
-- ADD GITSIGNS CONFIG THAT IS _NECESSARY_ FOR REPRODUCING THE ISSUE
on_attach = function(bufnr)
local gitsigns = require('gitsigns')
local function map(mode, l, r, opts)
opts = opts or {}
opts.buffer = bufnr
vim.keymap.set(mode, l, r, opts)
end
-- Text object
map({'o', 'x'}, 'ih', gitsigns.select_hunk)
end
}
-- ADD INIT.LUA SETTINGS THAT IS _NECESSARY_ FOR REPRODUCING THE ISSUE
Steps to reproduce
mkdir gitsigns_issue
cd gitsigns_issue
git init
touch file
git add file
git commit -m 'initial commit'
nvim --clean -u minimal.lua file
- Edit the file to add a changed hunk
- Press
vih
with the cursor on the hunk
Gitsigns debug messages
E5108: Error executing lua: ...gns_issue/gitsigns_issue/gitsigns/lua/gitsigns/async.lua:99: timeout must be >= 0
stack traceback:
[C]: in function 'wait'
...gns_issue/gitsigns_issue/gitsigns/lua/gitsigns/async.lua:99: in function 'pwait'
...gns_issue/gitsigns_issue/gitsigns/lua/gitsigns/async.lua:120: in function 'wait'
...s_issue/gitsigns_issue/gitsigns/lua/gitsigns/actions.lua:955: in function <...s_issue/gitsigns_issue/gitsigns/lua/gitsigns/actions.lua:946>
Gitsigns cache
wochap
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working