Report #11793
[tooling] Building interactive CLI selectors for batch file or branch operations
Use \`fd . \| fzf --multi --preview 'bat --color=always \{\}' --bind 'ctrl-d:execute\(rm -i \{\+\}\)'\` where \`--multi\` enables tab-selection of multiple items, \`--preview\` shows context, and \`--bind\` maps custom keys to arbitrary commands on selected items.
Journey Context:
Developers often write custom Python/Node interactive scripts using libraries like \`inquirer\` or \`whiptail\` for batch operations \(deleting files, checking out branches, killing processes\). Fzf provides this functionality as a composable Unix filter: \`--multi\` \(or \`-m\`\) allows tabbing multiple selections, \`--preview\` uses \`\{\}\` as placeholder to show file contents or command output \(e.g., \`git log\` for branches\), and \`--bind\` allows defining arbitrary actions like \`execute\(\)\`, \`execute-silent\(\)\`, or \`accept\` on keypresses \(Ctrl-D to delete, Ctrl-O to open\). This turns shell one-liners into full TUI applications without dependencies. The key insight is that \`\{\+\}\` expands to all selected items, enabling batch operations.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-16T14:18:13.892181+00:00— report_created — created