terminal-bash Stinger
The procedural arsenal for terminal-bash-wasp-drone. This stinger encodes the opinionated playbooks for every layer of the terminal productivity stack: shell runtime, modern CLI tooling, scripting safety, dotfile architecture, terminal multiplexer setup, and task automation.
When invoked, read SKILL.md first, then the relevant guide(s) for the task at hand. Research files confirm every factual claim; cite them when answering questions.
Scope and non-scope
In scope:
- Bash, Zsh, Fish shell configuration and migration
- Modern CLI tool adoption: ripgrep, fd, fzf, bat, eza, zoxide
- Shell scripting: safety patterns, quoting, error handling, trapping, getopts
- Dotfile architecture: XDG layout, bootstrap scripts, idempotency
- Terminal multiplexers: tmux 3.4+, Zellij 0.40+
- Task automation: just 1.30+, make (migration and coexistence)
- Shell prompts: Starship, p10k, tide (secondary - see
guides/00-principles.md)
Not in scope:
- CI/CD pipelines running inside containers -> ci-release-wasp-drone
- TypeScript/Node build and packaging (
tsconfig.json, esbuild, npm publish) -> typescript-node-wasp-drone
- OS-level system administration beyond a developer workstation
Seven-action playbook
The Drone performs seven distinct actions. Each maps to a guide:
| Action |
Guide |
| Audit shell configuration |
guides/01-shell-audit.md |
| Adopt modern CLI tools |
guides/02-modern-cli-tools.md |
| Review and fix shell scripts |
guides/03-shell-scripting.md |
| Design dotfile structure |
guides/03-shell-scripting.md (dotfile section) |
| Set up tmux or Zellij |
guides/04-tmux-zellij.md |
| Set up or migrate task automation |
guides/05-task-automation.md |
| Author findings report |
templates/findings-report.md |
Critical directives (from Command Brief)
These are non-negotiables. Full justifications in guides/00-principles.md.
- Check portability first. Before writing Bash-specific syntax, determine whether the script must run on POSIX
sh. Always ask or default to POSIX-safe unless context is clearly Bash-only.
- Never
set -e alone. The full trio is set -euo pipefail. Half-measures leave pipeline failures and unbound variables silent.
- Quote every variable expansion.
"$var" not $var. Exception: arithmetic contexts $((...)).
- Explain tool trade-offs. ripgrep ignores hidden files by default. fd skips dotfiles. bat is not a drop-in pipe replacement. Always surface the gotcha when recommending.
- Keep dotfile changes idempotent. Bootstrap scripts run repeatedly; source-guarding and
mkdir -p patterns prevent accumulation.
- Escalate container scripts to ci-release-wasp-drone. Container environments may have different shell versions and missing tools. Overlapping silently produces fragile CI.
Folder layout
terminal-bash-stinger/
├── SKILL.md (this file - master index)
├── README.md (human overview)
├── guides/
│ ├── 00-principles.md (portability tiers, escalation rules, shellcheck policy)
│ ├── 01-shell-audit.md (how to audit .bashrc/.zshrc/config.fish)
│ ├── 02-modern-cli-tools.md (replacement matrix + init snippets)
│ ├── 03-shell-scripting.md (set -euo pipefail, quoting, traps, dotfiles)
│ ├── 04-tmux-zellij.md (config, plugins, session persistence)
│ └── 05-task-automation.md (just vs make, justfile patterns)
├── examples/
│ ├── happy-path.md (full dotfile setup from scratch)
│ └── script-review.md (review of a real-world shell script)
├── templates/
│ ├── bash-script-template.sh (safe Bash script skeleton)
│ ├── justfile-template.md (documented justfile starter)
│ └── findings-report.md (report shape for terminal audits)
├── reports/
│ └── README.md (past run summaries accumulate here)
└── research/ (authored by scripture-historian - DO NOT MODIFY)
├── research-plan.md
├── research-summary.md
├── index.md
├── internal/
└── external/
Quick reference: the modern CLI stack
| Legacy |
Modern |
Key gotcha |
grep |
rg (ripgrep) |
Ignores hidden files by default; use --hidden |
find |
fd |
Skips dotfiles by default; use -H |
cat |
bat |
Not a drop-in for pipes; use --plain --no-pager |
ls |
eza |
Not in all distro repos; may need cargo install |
cd |
zoxide |
Requires visit-history; z won't work on unvisited dirs |
Ctrl-R |
fzf |
Preview spawns subshell; expensive in large repos |
Part of The Wasp Nest, curated by Mario Aldayuz a.k.a @thenotoriousllama.
1---2name: terminal-bash-stinger-33license: AGPL-3.0-or-later4description: "Improve terminal workflows. Use for Bash, Zsh, Fish, modern CLI tools, dotfiles, tmux, or just/make automation. Read README.md for the guide map."5metadata:6 source: https://skillmd.com/skills/legioncodeinc/terminal-bash-stinger-37---89# terminal-bash Stinger1011The procedural arsenal for `terminal-bash-wasp-drone`. This stinger encodes the opinionated playbooks for every layer of the terminal productivity stack: shell runtime, modern CLI tooling, scripting safety, dotfile architecture, terminal multiplexer setup, and task automation.1213**When invoked, read `SKILL.md` first, then the relevant guide(s) for the task at hand. Research files confirm every factual claim; cite them when answering questions.**1415---1617## Scope and non-scope1819**In scope:**20- Bash, Zsh, Fish shell configuration and migration21- Modern CLI tool adoption: ripgrep, fd, fzf, bat, eza, zoxide22- Shell scripting: safety patterns, quoting, error handling, trapping, getopts23- Dotfile architecture: XDG layout, bootstrap scripts, idempotency24- Terminal multiplexers: tmux 3.4+, Zellij 0.40+25- Task automation: just 1.30+, make (migration and coexistence)26- Shell prompts: Starship, p10k, tide (secondary - see `guides/00-principles.md`)2728**Not in scope:**29- CI/CD pipelines running inside containers -> ci-release-wasp-drone30- TypeScript/Node build and packaging (`tsconfig.json`, `esbuild`, npm publish) -> typescript-node-wasp-drone31- OS-level system administration beyond a developer workstation3233---3435## Seven-action playbook3637The Drone performs seven distinct actions. Each maps to a guide:3839| Action | Guide |40|---|---|41| Audit shell configuration | `guides/01-shell-audit.md` |42| Adopt modern CLI tools | `guides/02-modern-cli-tools.md` |43| Review and fix shell scripts | `guides/03-shell-scripting.md` |44| Design dotfile structure | `guides/03-shell-scripting.md` (dotfile section) |45| Set up tmux or Zellij | `guides/04-tmux-zellij.md` |46| Set up or migrate task automation | `guides/05-task-automation.md` |47| Author findings report | `templates/findings-report.md` |4849---5051## Critical directives (from Command Brief)5253These are non-negotiables. Full justifications in `guides/00-principles.md`.54551. **Check portability first.** Before writing Bash-specific syntax, determine whether the script must run on POSIX `sh`. Always ask or default to POSIX-safe unless context is clearly Bash-only.562. **Never `set -e` alone.** The full trio is `set -euo pipefail`. Half-measures leave pipeline failures and unbound variables silent.573. **Quote every variable expansion.** `"$var"` not `$var`. Exception: arithmetic contexts `$((...))`.584. **Explain tool trade-offs.** ripgrep ignores hidden files by default. fd skips dotfiles. bat is not a drop-in pipe replacement. Always surface the gotcha when recommending.595. **Keep dotfile changes idempotent.** Bootstrap scripts run repeatedly; source-guarding and `mkdir -p` patterns prevent accumulation.606. **Escalate container scripts to ci-release-wasp-drone.** Container environments may have different shell versions and missing tools. Overlapping silently produces fragile CI.6162---6364## Folder layout6566```text67terminal-bash-stinger/68├── SKILL.md (this file - master index)69├── README.md (human overview)70├── guides/71│ ├── 00-principles.md (portability tiers, escalation rules, shellcheck policy)72│ ├── 01-shell-audit.md (how to audit .bashrc/.zshrc/config.fish)73│ ├── 02-modern-cli-tools.md (replacement matrix + init snippets)74│ ├── 03-shell-scripting.md (set -euo pipefail, quoting, traps, dotfiles)75│ ├── 04-tmux-zellij.md (config, plugins, session persistence)76│ └── 05-task-automation.md (just vs make, justfile patterns)77├── examples/78│ ├── happy-path.md (full dotfile setup from scratch)79│ └── script-review.md (review of a real-world shell script)80├── templates/81│ ├── bash-script-template.sh (safe Bash script skeleton)82│ ├── justfile-template.md (documented justfile starter)83│ └── findings-report.md (report shape for terminal audits)84├── reports/85│ └── README.md (past run summaries accumulate here)86└── research/ (authored by scripture-historian - DO NOT MODIFY)87 ├── research-plan.md88 ├── research-summary.md89 ├── index.md90 ├── internal/91 └── external/92```9394---9596## Quick reference: the modern CLI stack9798| Legacy | Modern | Key gotcha |99|---|---|---|100| `grep` | `rg` (ripgrep) | Ignores hidden files by default; use `--hidden` |101| `find` | `fd` | Skips dotfiles by default; use `-H` |102| `cat` | `bat` | Not a drop-in for pipes; use `--plain --no-pager` |103| `ls` | `eza` | Not in all distro repos; may need cargo install |104| `cd` | `zoxide` | Requires visit-history; `z` won't work on unvisited dirs |105| `Ctrl-R` | `fzf` | Preview spawns subshell; expensive in large repos |106107---108109*Part of The Wasp Nest, curated by [Mario Aldayuz a.k.a @thenotoriousllama](https://github.com/thenotoriousllama).*