● Field notes · liveLos Angeles
Alexander Cannon
← Back to projects

CLI

✓ Shipped

PathRanger

Rust CLI that remembers where you work and jumps you there – tags, recents, fuzzy search.

PathRanger

I built PathRanger to spend less time typing paths when switching between projects.

It keeps a history of visited directories and lets you find them with tags or fuzzy search. Shell hooks handle the directory change in bash, zsh, and fish.

Demo strip

$ pathranger init --shell zsh
$ pr goto portfolio
→ /Users/alexandercannon/fun/portfolio
$ pathranger search path
  1. …/fun/pathranger
  2. …/fun/portfolio

Built with

Rust · SQLite (rusqlite) · Skim fuzzy matcher · bash / zsh / fish init hooks

Technical challenges

  1. 01

    Wrapping `cd` in bash, zsh, and fish while preserving exit codes and normal shell behaviour.

  2. 02

    Returning the selected path on stdout so the shell wrapper can change the current directory.

  3. 03

    Fuzzy search over the visit database with sensible ranking for day-to-day use.

Role

I designed, built, and released it.