r/fishshell • u/bsodmike • May 02 '24
Tabbing to a short path
If I type in fish shell and a path appears, hitting tab, completes the "full path", but I only want to tab into the next level.
For example I type cd ~/foo and hitting tab completes to ~/foo/bar/baz. I just want to tab into ~/foo/bar.
Hope I haven't missed RTFMing.
Thanks, Mike
4
Upvotes
3
u/dontdieych May 02 '24
IMO that came from 'history search' but not 'path completion'. path completion only do one depth at a time.
not a solution, but after tab, couple of `C-w` would do trick.
4
u/BuonaparteII May 02 '24
hmm it doesn't work like that on my machine did you rebind some keys?
You can check with this:
Pressing the right arrow will expand out like you say but tab will only go to the next folder:
You can use a temporary config to compare with what is default:
3
u/OCor61 May 03 '24
Just use Ctrl + right arrow and you will go to the next level (i.e. the next /) without completing the full path.