howto is a tiny Go CLI that asks an installed LLM CLI (claude, codex, or opencode) for just the shell command you need.
- Auto-detects installed tool in this order:
claude,codex,opencode - Optional
--toolflag to force one - Passes prior shell command as context (best-effort from shell history)
- Sends strict prompt so output is command-only
- Easy local install with
go install
brew tap yosifonoren/tap
brew install howtoHOWTO_VERSION=$(curl -sL https://api.github.com/repos/yosifonoren/how-cli/releases/latest | sed -n 's/.*"tag_name": "v\([^"]*\)".*/\1/p')
curl -sLO "https://github.com/yosifonoren/how-cli/releases/latest/download/howto_${HOWTO_VERSION}_linux_$(dpkg --print-architecture).deb"
sudo dpkg -i howto_${HOWTO_VERSION}_linux_$(dpkg --print-architecture).debgo install github.com/yosifonoren/how-cli/cmd/howto@latestgit clone https://github.com/yosifonoren/how-cli.git
cd how-cli
go install ./cmd/howtohowto <your request>
howto --tool claude <your request>
howto --no-history <your request>howto how do i list all files recursively
howto --tool codex how do i find all go files changed in last 2 daysThe tool creates a prompt with:
- A strict system instruction: return only one shell command.
- Your request.
- Previous command from shell history (unless
--no-historyis used).
History is read best-effort from:
$HISTFILE(if set)~/.zsh_history~/.bash_history~/.config/fish/fish_history
go run ./cmd/howto --help
go run ./cmd/howto how do i list hidden filesgo test ./...go fmt ./...
go vet ./...go install ./cmd/howtoAfter code changes, repeat the cycle: go test, go vet, and go install.
At least one of these LLM CLIs must be installed and in your PATH:
- Claude Code (
claude) - Codex CLI (
codex) - OpenCode (
opencode)
If none are found, howto exits with a clear error.
