4 ms·
z foo # cd into highest ranked directory matching foo z foo bar # cd into highest ranked directory matching foo and bar z foo /
by Leftium 3y ago
z foo # cd into highest ranked directory matching foo
z foo bar # cd into highest ranked directory matching foo and bar
z foo / # cd into a subdirectory starting with foo
z ~/foo # z also works like a regular cd command
z foo/ # cd into relative path
z .. # cd one level up
z - # cd into previous directory
zi foo # cd with interactive selection (using fzf)
z foo<SPACE><TAB> # show interactive completions (zoxide v0.8.0+, bash 4.4+/fish/zsh only)
- jvanderbot 3y agoIt appears to me that these could all be just tab complete, fzf, or similar. Some are just plain old bash. The commands are written in rust, presumably because they're part of this warp shell advertised on readme?
- dtj1123 3y agoYou can't use tab complete to easily navigate to a directory with a non-trivial relative path. Zoxide lets you type an arbitrary substring of the directory you want to navigate to, regardless of where you currently are. No, warp appears to be a sponsor, nothing more.
- 149765 3y agofzf (golang) readme also has the same banner.
- fatnoah 3y agoI really want to like Warp, but I just can "untrain" my brain from years of visually grokking terminal outputs. Despite it's features, it's impossible (based on my experience and feature requests in their GitHub account) to recreate my simple and preferred shell prompt that includes git branch, date/time, and full path without tons of extraneous whitespace. It's a small thing, but my brain can't handle it for some reason.
- Leftium 3y agoI think Warp is just a project sponsor (i.e. advertisement: "Special thanks to:"). I don't even know what Warp is... I am using zoxide fine without Warp. (Windows + git-bash.) (And my shell prompt is just the full path + git-branch ^^)
- jackthetab 3y agoWait. You can jump to the directory `~/projects/foo/python/bar` by typing `<some_cmd> foo bar` in POB (plain ole' bash)?! That's the main feature I love about zoxide; it's be great if I could do it natively.
- reaperman 3y agoBest I can come up with is adding the following to .bashrc: function jump() { local current_dir=$(pwd) local search_pattern="*" for arg in "$@"; do search_pattern+="$arg*" done local path_found=$(find "$current_dir" -type d -path "$search_pattern" -print -quit) if [[ -n $path_found ]]; then cd "$path_found" || return else echo "Directory not found from here." fi } Then jump foo bar {baz ...} does what you'd like here. e.g. me@myhost ~ % jump CMake doc guide will go to /Users/me/Qt/Tools/CMake/CMake.app/Contents/doc/cmake/html/guide/
- jvanderbot 3y agoI used to use this https://github.com/jodavaho/smartcd https://github.com/jodavaho/smartcd 'scd journal' 'scd logs personal' Now I tab complete using fzf, but the above is what you want. Bash is Turing complete. You "need" nothing else. You may want it for various reasons.