practicalli

Lucio Assis 2023-12-07T18:15:59.579759Z

Is there a shortcut to jump to the next hunk or change? I'd like to be able to jump to the region below, where I knew there was a change in the file but it was not until line 1360. I'm using Practicalli AstroNvim

Lucio Assis 2023-12-07T18:22:26.928649Z

Just found this, but here's my scenario:

Lucio Assis 2023-12-07T18:24:10.728159Z

I took a WIP commit I had done earlier and I reset the branch back to its parent commit. Everything then comes back to the working dir as modifications as far as git is concerned, and the change points are marked as such in the sidebar when the file is open, but the shortcuts above don't work

Lucio Assis 2023-12-07T18:24:25.520049Z

If I then go and make further changes, I can navigate to those with those shortcuts, but only those - which are the same ones I see in the :changes list.

practicalli-johnny 2023-12-07T22:53:38.646579Z

Gitsigns plugin says it can navigate hunks, although I haven't tried this yet. [c and ]c may be mapped already. If not, the GitHub readme for the project has an example mapping https://github.com/lewis6991/gitsigns.nvim#keymaps

practicalli-johnny 2023-12-07T23:32:35.657779Z

Seems AstroNvim has [g and ]g mapped to navigate between hunks already

Lucio Assis 2023-12-08T14:34:18.184269Z

It does, awesome!

Lucio Assis 2023-12-08T14:34:18.889649Z

Thanks

Lucio Assis 2023-12-08T14:41:26.917349Z

I need to get used to the fact that ] and [ have lots of previous/next navigation options

Lucio Assis 2023-12-08T14:42:07.522369Z

It works in neotree too 💕

practicalli-johnny 2023-12-08T15:19:12.504339Z

Ah, in neotree as well, that is good to know. Thank you for helping me learn more.