3 ms·
Wow. While this is quite slick (and must have been funny to implement), I actually hate this kind of "magic" behavior.
by enriquto 6y ago
Wow. While this is quite slick (and must have been funny to implement), I actually hate this kind of "magic" behavior.
- pletnes 6y agoHow is it more or less magic than bash’s? It takes more context into account, sure, but it’s easy to understand and reason about.
- polack 6y agoI usually hate magic too, but I have to say this is one of the cases where I like it. It's convenient without any danger attached to it since you're just switching directory and not actually executing something against this "unknown" path.
- Jach 6y agoFor about a decade I've had in my bashrc C() { cd `$HOME/path-selector.sh "$@"`; } where path-selector is from https://github.com/MarcWeber/path-selector https://github.com/MarcWeber/path-selector Opt-in bash extensions can do basically whatever people complain bash can't do. Though to be honest I don't use it that much over the last, say, 5 years. If I know a deep directory tree that well, I can just type it explicitly and/or tab complete it without losing much time. If I don't know it that well, FZF is quite nice.