›wib

wib · what is that bash?

The command you ran last week, before you ask.

Type two letters and wib lists the zsh commands you already ran, right under your prompt. Press ↓ then Enter to run one.

~/code/api on main
  • git push origin master
  • git status
  • git commit -m "fix bug"
Prefix match: your most used git commands come first.
Tap the person at the desk.
A lookup Five steps on index cards: you type gi, wib reads your history, matches by prefix then word starts, ranks by how often, how recently and where you ran it, and shows up to 8 lines under your prompt. wib · I A lookup per keystroke, about 5 ms g i you type gi read history match rank show the list a process starts last 30 days prefix, then word starts often, recent, here first up to 8 lines under your prompt
I

A lookup

per keystroke, about 5 ms

Every key you type starts a short process that reads your history, matches, ranks and prints the list, then exits. Nothing stays running.

Who comes first You type g. Four matches in order: git push origin master, used most often; git status, which wins the tie because you ran it in this repository; grep -rn TODO src, used less; and gti status, which never worked, so it sinks to the bottom. The failed command and its path are red. wib · II Who first ranked by how you work % g git push origin master git status grep -rn TODO src gti status sinks most often ran in this repo used less never worked
II

Who comes first

ranked by how you work

What you use most and most recently rises to the top, and commands you ran in this repository win ties. The red card never worked, so it sinks below the rest without being hidden.

Your keys Five states. You start typing. Esc or Ctrl-G hides the list; typing again shows it. Down starts selecting. While selecting, down and up move; up at the top or Space goes back to typing. Enter runs the command. Tab fills it in without running. wib · III Your keys typing and selecting hidden typing selecting it runs filled in Esc you type down up at top, or Space down, up: move Enter Tab esc
III

Your keys

typing and selecting

Keys only change meaning after you press down. Until then, up, Tab, Space and Enter do what zsh always did, and Ctrl-R is never touched.

Word by word You typed gi and selected git push origin master. Each Shift+Tab adds one word: git, then git push, then git push origin, then git push origin master. Four presses, five strips. wib · IV Word by word Shift+Tab, four times reuse it as a template gi git git push git push origin git push origin master Shift+Tab Shift+Tab Shift+Tab Shift+Tab shift tab
IV

Word by word

Shift+Tab, four times

Select an old command and take only the words you need, then edit the end. A quoted string like "fix bug" fills in a single press.

Type less, still land on the right command

Prefix matches come first, then the first letters of each word. Letters scattered through the middle of words don't count, so the list stays short.

gi
git push origin master
Prefix. The commands you start most often rise to the top.
dcup
docker compose up
Word starts: docker compose up.
gi st
git status
Each chunk you type must start a word in the command.
wib pull,master
git pull origin master
Keyword search. Remember a few words, in any order.

Ranked by how you actually work

Duplicates collapse to one line. What you reach for most is what you see first.

Fix a typo, reuse a template, keep secrets out

Small helpers around the list. None of them adds a process when a command succeeds, and none of them runs anything for you.

New in v0.2.0. See the changelog for every version.

Suggestions that appear on their own

Ctrl-R and fzf make you stop and open a search. wib refines a list with every keystroke, and your keys keep working as before until you press ↓.

ToolHow you invoke itSuggestionsMulti-machine sync
wibAppears as you typeSeveral lines, right under the promptNo, local only
zsh-autosuggestionsAppears as you typeOne grey hintNo
Ctrl-R / fzfPress a key to openSearch listNo
atuinPress a key to openSearch listYes

wib runs alongside oh-my-zsh, powerlevel10k, zsh-autosuggestions and vi mode.

Fast enough to run on every keystroke

Each lookup is a short-lived process that reads your history and exits. No index, no daemon, nothing that grows while your terminal stays open.

5.4 ms
p95 lookup on 10,000 commands, process startup included
8.8 ms
p95 lookup on 100,000 commands over 400 days
~2 MB
peak memory per lookup on the 10,000-command file
0600
file mode of wib's log. Nothing leaves your machine.

Measured with scripts/bench.sh on macOS, 100 lookups per file, WIB_PERIOD=30d.

Install in a minute

Prebuilt binaries from the v0.2.0 release. No Rust toolchain needed.

Requires zsh 5.3 or newer. Your existing ~/.zsh_history works from the first prompt.

Using Homebrew? Run brew install duylongpro99/tap/wib in place of step 1.

Choose your platform
  1. Download, verify and unpack

    curl -fsSL -O https://github.com/duylongpro99/wuts-that-bash/releases/download/v0.2.0/wib-aarch64-apple-darwin.tar.gz -O https://github.com/duylongpro99/wuts-that-bash/releases/download/v0.2.0/wib-aarch64-apple-darwin.tar.gz.sha256
    shasum -a 256 -c wib-aarch64-apple-darwin.tar.gz.sha256 &&
      tar -xzf wib-aarch64-apple-darwin.tar.gz &&
      mkdir -p ~/.local/bin && mv wib-aarch64-apple-darwin/wib ~/.local/bin/
    Download .tar.gz
    curl -fsSL -O https://github.com/duylongpro99/wuts-that-bash/releases/download/v0.2.0/wib-x86_64-apple-darwin.tar.gz -O https://github.com/duylongpro99/wuts-that-bash/releases/download/v0.2.0/wib-x86_64-apple-darwin.tar.gz.sha256
    shasum -a 256 -c wib-x86_64-apple-darwin.tar.gz.sha256 &&
      tar -xzf wib-x86_64-apple-darwin.tar.gz &&
      mkdir -p ~/.local/bin && mv wib-x86_64-apple-darwin/wib ~/.local/bin/
    Download .tar.gz
    curl -fsSL -O https://github.com/duylongpro99/wuts-that-bash/releases/download/v0.2.0/wib-x86_64-unknown-linux-musl.tar.gz -O https://github.com/duylongpro99/wuts-that-bash/releases/download/v0.2.0/wib-x86_64-unknown-linux-musl.tar.gz.sha256
    sha256sum -c wib-x86_64-unknown-linux-musl.tar.gz.sha256 &&
      tar -xzf wib-x86_64-unknown-linux-musl.tar.gz &&
      mkdir -p ~/.local/bin && mv wib-x86_64-unknown-linux-musl/wib ~/.local/bin/
    Download .tar.gz
    curl -fsSL -O https://github.com/duylongpro99/wuts-that-bash/releases/download/v0.2.0/wib-aarch64-unknown-linux-musl.tar.gz -O https://github.com/duylongpro99/wuts-that-bash/releases/download/v0.2.0/wib-aarch64-unknown-linux-musl.tar.gz.sha256
    sha256sum -c wib-aarch64-unknown-linux-musl.tar.gz.sha256 &&
      tar -xzf wib-aarch64-unknown-linux-musl.tar.gz &&
      mkdir -p ~/.local/bin && mv wib-aarch64-unknown-linux-musl/wib ~/.local/bin/
    Download .tar.gz

    Downloaded with a browser on macOS? Clear the quarantine flag once with xattr -d com.apple.quarantine ~/.local/bin/wib. The second line checks the archive against its .sha256 checksum and stops if the download is damaged or incomplete.

  2. Hook it into zsh

    Add these to the end of ~/.zshrc, after oh-my-zsh and other plugins.

    echo 'export PATH="$HOME/.local/bin:$PATH"' >> ~/.zshrc
    echo 'eval "$(wib init zsh)"' >> ~/.zshrc
  3. Open a new terminal

    Type gi and your git commands are already there.

Copy a command and watch.

Upgrading: run brew upgrade wib, or repeat step 1 only, then open a new terminal. Your history and settings stay as they are.

Your keys keep their meaning

Keys only change once you press ↓ to select a line. Ctrl-R, completion and history are untouched.

↓
Start selecting, then move down the list
Enter
Run the selected command
Tab
Fill the selected command without running it
Shift Tab
Fill it word by word, to reuse it as a template
Esc
Hide the list until you type again
Ctrl ]
Jump to the next part that changed between earlier runs
wib forget
Never suggest a wrong or secret command again
Press ↓, Enter, Tab or Esc here, or tap a row.