Prefer --filter when running without an interactive TTY.
Handle cancel/no-result paths explicitly in scripts.
Common Pitfalls
Exit code 130 indicates cancel, not regular no-results.
--multi emits newline-separated selections and needs downstream handling.
Environment defaults such as FZF_DEFAULT_COMMAND can change behavior.
Output Interpretation
Interactive mode prints selected line(s) to stdout.
--filter prints matches non-interactively and returns 0/1.
Why It Matters For Agents
Supports both human-driven and fully scripted fuzzy selection.
Enables ergonomic choice workflows without custom UI development.
Repo Conventions
Use fzf for user-choice steps, not mandatory automation paths.
Keep deterministic fallbacks for non-interactive environments.
Trigger Examples
Should trigger: "Let me choose a branch interactively from a list."
Should trigger: "Add a fuzzy file picker to this script."
Should not trigger: "Run a static shell linter on this script."
1---2name: tool-fzf-23description: tool-fzf4---5# tool-fzf67## When To Use89- Add interactive selection to shell workflows.10- Narrow large candidate lists quickly with fuzzy matching.11- Run non-interactive fuzzy filtering in scripted pipelines.1213## Trusted Commands1415```bash16fzf17git branch --all | fzf18fd -t f | fzf19fzf --preview 'bat --color=always {}'20printf '%s\n' foo bar baz | fzf --filter 'ba'21fzf --multi22```2324## Safe Defaults2526- Use clear prompts and scoped input lists.27- Prefer `--filter` when running without an interactive TTY.28- Handle cancel/no-result paths explicitly in scripts.2930## Common Pitfalls3132- Exit code `130` indicates cancel, not regular no-results.33- `--multi` emits newline-separated selections and needs downstream handling.34- Environment defaults such as `FZF_DEFAULT_COMMAND` can change behavior.3536## Output Interpretation3738- Interactive mode prints selected line(s) to stdout.39- `--filter` prints matches non-interactively and returns 0/1.4041## Why It Matters For Agents4243- Supports both human-driven and fully scripted fuzzy selection.44- Enables ergonomic choice workflows without custom UI development.4546## Repo Conventions4748- Use fzf for user-choice steps, not mandatory automation paths.49- Keep deterministic fallbacks for non-interactive environments.5051## Trigger Examples5253- Should trigger: "Let me choose a branch interactively from a list."54- Should trigger: "Add a fuzzy file picker to this script."55- Should not trigger: "Run a static shell linter on this script."
Run npx skillmds@latest add niksavis/tool-fzf-2 in your terminal (requires Node.js), paste this page's agent-chat prompt into Claude, Cursor, or any MCP-connected agent, or download the SKILL.md file and copy it into your agent's skills directory.
tool-fzf It is listed under Coding & Dev Tools on SkillMD.
This skill has not completed SkillMD's automated safety review yet. SkillMD never runs a skill's scripts for you; review the SKILL.md before installing.
This skill is tagged as working with Claude Code, Claude.ai, OpenAI Codex. SKILL.md is an open format, so most agents that read a skills directory can load it too.
Yes. Installing skills from SkillMD is free, and the skill stays under its author's original license.
niksavis (@niksavis) published this skill. Their other Agent Skills are listed on their SkillMD profile.