Expert guidance for POSIX shell and Bash scripting. Use when working in `.sh` files or when the task depends on shell portability, Bash features, safety flags, traps, parameter expansion, or cross-platform command behavior.
Use this skill for shell-specific decisions. Keep it about shell behavior, not generic coding workflow.
Open only the reference that matches the current constraint:
| Need | Open |
|---|---|
Maximum portability or sh compatibility | posix-scripting |
Bash-only features such as arrays or [[ ... ]] | bash-features |
| Safer scripts, argument handling, cleanup, traps | defensive-patterns |
| macOS vs Linux command differences | cross-platform |
Use this skill for:
Do not use this skill as the primary guide for:
sh or can require Bash.Identify the contract.
sh vs Bash and note the target platforms.Choose the narrowest reference.
Apply the smallest safe pattern.
Verify behavior directly.
This skill is being applied well when: