Our great sponsors
-
WorkOS
The modern identity platform for B2B SaaS. The APIs are flexible and easy-to-use, supporting authentication, user identity, and complex enterprise features like SSO and SCIM provisioning.
-
InfluxDB
Power Real-Time Data Analytics at Scale. Get real-time insights from all types of time series data with InfluxDB. Ingest, query, and analyze billions of data points in real-time with unbounded cardinality.
-
fishmarks
Bookmark and jump to directories faster than a sailfish! Fishmarks is a clone of bashmarks for the Fish shell.
-
SaaSHub
SaaSHub - Software Alternatives and Reviews. SaaSHub helps you find the best software and product alternatives
https://github.com/skywind3000/z.lua was another that I used for a long time, although I've lately started using https://github.com/jethrokuan/z
A lot of reinventing the wheel in the z space it seems
FYI for windows, I made this a long time ago:
https://github.com/tkellogg/Jump-Location
Which was fun and all, but eventually replaced by a pure PowerShell implementation that's become far more active:
https://github.com/vors/ZLocation
FYI for windows, I made this a long time ago:
https://github.com/tkellogg/Jump-Location
Which was fun and all, but eventually replaced by a pure PowerShell implementation that's become far more active:
https://github.com/vors/ZLocation
I use this Rust clone which works great, no complaints: https://github.com/ajeetdsouza/zoxide
Although, I don't know what the difference is, other than the language of choice.
You call it with `n` and get an interactive fuzzy search for your directories. If you do `n ` instead, it’ll start the find with `` already filled in (and if there’s only one match, jump to it directly). The `ls` is optional but I find that I like having the contents visible as soon as I change a directory.
I’m also including iCloud Drive but excluding the Library directory as that is too noisy. I have a separate `nl` function which searches just inside `~/Library` for when I need it, as well as other specialised `n` functions that search inside specific places that I need a lot.
¹ https://github.com/sharkdp/fd
² https://github.com/junegunn/fzf
You call it with `n` and get an interactive fuzzy search for your directories. If you do `n ` instead, it’ll start the find with `` already filled in (and if there’s only one match, jump to it directly). The `ls` is optional but I find that I like having the contents visible as soon as I change a directory.
I’m also including iCloud Drive but excluding the Library directory as that is too noisy. I have a separate `nl` function which searches just inside `~/Library` for when I need it, as well as other specialised `n` functions that search inside specific places that I need a lot.
¹ https://github.com/sharkdp/fd
² https://github.com/junegunn/fzf
I was frustrated with jumping to frecent directories, so I "reverted" back to jumping back to bookmarked directories [0] (which I find much more predictable).
0: https://github.com/techwizrd/fishmarks
I used something different, but it didn't work as expected because I have multiple directories that start with the same name letter. Consequently, the shortcuts changed their paths and I never ended up where I wanted.
I built my own tool called Zee, that takes a simplified approach by only utilizing explicit user-defined shortcuts: https://github.com/dnsv/zee
Yes, I made a similar keybinding for xonsh, using fd and fzf. I press Alt-c, and fzf shows me all the subdirectories rooted where I'm at.
That's a good intermediary solution. But the one that totally changed my flow was to combine autojump[1] and fzf. autojump is similar to Z (this submission). It stores all the directories you've visited in an SQLite DB and can show them to you (ordered by visit frequency) with a command line argument. So I pipe that to fzf.
Now I can extremely quickly jump to any directory I've been to before - it really helps that they're sorted by visit frequency. I honestly use this more than any other approach - and I probably go for days on end without using the usual TAB autocompletion.
[1] https://github.com/wting/autojump
It seems like the Rust community is quite happy to support alternative shells. I’ve seen couple of projects, now, that support way more esoteric shells than I would expect, like ’xonsh’. Starship (https://starship.rs/) immediately comes to mind.
I've been using enhancd for years now.
https://github.com/babarot/enhancd
Heavy user of `z` for many years that is until it dropped its database one final time. There's nothing more frustrating then a dropped or corrupted directory database just as you've got the damn thing to remember all your favourite spots on the disk.
These days I use https://github.com/gsamokovarov/jump which I've mapped to `z`. Happy days.
Came to post zoxide. Also if you use `ranger`[1] (vim inspired file manager) then you might like to add the `ranger-zoxide` plugin[2].
1. https://github.com/ranger/ranger
2. https://github.com/jchook/ranger-zoxide
Came to post zoxide. Also if you use `ranger`[1] (vim inspired file manager) then you might like to add the `ranger-zoxide` plugin[2].
1. https://github.com/ranger/ranger
2. https://github.com/jchook/ranger-zoxide
Related posts
- Ask HN: Any tool for managing large and variable command lines?
- Show HN: Inshellisense – IDE style shell autocomplete
- How to achieve the function of the Mac app Hookmark in the terminal?
- How do you guys keep a list of the commands you gotta run across different projects?
- A tmux plugin to make creating/switching sessions easier