Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx skills add ericrisco/rsc-harness --skill bash-scriptinggit clone --depth 1 https://github.com/ericrisco/rsc-harnessWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/skills/ericrisco/rsc-harness/bash-scripting)<a href="https://agentmods.dev/skills/ericrisco/rsc-harness/bash-scripting"><img src="https://agentmods.dev/badge/skills/ericrisco/rsc-harness/bash-scripting/github.svg" alt="Measured on agentmods" height="20"></a>Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.
<a href="https://agentmods.dev/skills/ericrisco/rsc-harness/bash-scripting"><img src="https://agentmods.dev/badge/skills/ericrisco/rsc-harness/bash-scripting.svg" alt="Reviewed on agentmods" width="80" height="20"></a>- NVIDIA SkillSpector warn
SkillSpector: 10 findings, up to high
These are SkillSpector’s own severities. On a checked sample its high-severity flags on skills were ~96% false positives — a documented command, a public API, a “never do X” rule — so we show them as a caution to read, not a verdict. Why →
- high Tool Misuse · line 12 Tool parameters are crafted to achieve unintended or unsafe behavior. Parameter abuse can bypass intended safety checks (e.g. shell=True, --force, dangerous glob patterns).Fix: Validate all tool parameters against an allowlist. Reject dangerous parameter values (shell=True, --force, -rf /) and use safe defaults.
- high Tool Misuse · line 93 Tool parameters are crafted to achieve unintended or unsafe behavior. Parameter abuse can bypass intended safety checks (e.g. shell=True, --force, dangerous glob patterns).Fix: Validate all tool parameters against an allowlist. Reject dangerous parameter values (shell=True, --force, -rf /) and use safe defaults.
- high Tool Misuse · line 95 Tool parameters are crafted to achieve unintended or unsafe behavior. Parameter abuse can bypass intended safety checks (e.g. shell=True, --force, dangerous glob patterns).Fix: Validate all tool parameters against an allowlist. Reject dangerous parameter values (shell=True, --force, -rf /) and use safe defaults.
- high Tool Misuse · line 96 Tool parameters are crafted to achieve unintended or unsafe behavior. Parameter abuse can bypass intended safety checks (e.g. shell=True, --force, dangerous glob patterns).Fix: Validate all tool parameters against an allowlist. Reject dangerous parameter values (shell=True, --force, -rf /) and use safe defaults.
- high Tool Misuse · line 96 Tool parameters are crafted to achieve unintended or unsafe behavior. Parameter abuse can bypass intended safety checks (e.g. shell=True, --force, dangerous glob patterns).Fix: Validate all tool parameters against an allowlist. Reject dangerous parameter values (shell=True, --force, -rf /) and use safe defaults.
- high Tool Misuse · line 100 Tool parameters are crafted to achieve unintended or unsafe behavior. Parameter abuse can bypass intended safety checks (e.g. shell=True, --force, dangerous glob patterns).Fix: Validate all tool parameters against an allowlist. Reject dangerous parameter values (shell=True, --force, -rf /) and use safe defaults.
- high Tool Misuse · line 158 Tool calls are chained to bypass individual safety checks or escalate capabilities beyond what any single tool call would allow.Fix: Limit tool chaining depth and validate the output of each tool before passing it to the next. Require explicit user approval for multi-step chains.
- high Tool Misuse · line 220 Tool calls are chained to bypass individual safety checks or escalate capabilities beyond what any single tool call would allow.Fix: Limit tool chaining depth and validate the output of each tool before passing it to the next. Require explicit user approval for multi-step chains.
- medium MCP Rug Pull · line 114 Docker image references without a specific tag (:latest is implicit) or digest (@sha256:...) can be silently replaced by a malicious image.Fix: Pin the image: image:tag or image@sha256:abc123
- medium MCP Rug Pull · line 118 Docker image references without a specific tag (:latest is implicit) or digest (@sha256:...) can be silently replaced by a malicious image.Fix: Pin the image: image:tag or image@sha256:abc123
What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00082 | $0.02937 |
| Opus 5.5 | $0.00033 | $0.01175 |
| Sonnet 5.5 | $0.00016 | $0.00587 |
| Haiku 4.5 | $0.00008 | $0.00294 |
Grade B, and why
bash-scripting scanned grade B with 2 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 1mo ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Recursive force deletemediumDestructive command
rm -rf with a variable or a broad path is one typo away from removing the wrong tree.
exploded a path with spaces, by `rm -rf "$DIR/"` where `$DIR` was empty, by a Downgraded: this mod is about security review, or the phrase is quoted, so it is likely naming the pattern rather than instructing it.
Makes network callslowCapability
Not a fault in itself. Listed so you know the mod talks to something, and to what.
local x=$(curl -fsS "$url") How it starts
The opening of the file, as written. The whole thing — 228 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Bash scripting — scripts that survive a stranger's machine
You are the shell author who has been burned: by an unquoted "$@" that
exploded a path with spaces, by rm -rf "$DIR/" where $DIR was empty, by a
trap that fired twice, by a set -e that swore it caught errors and didn't.
Write every script as if it will run in CI, in a container, and on a 2014 Mac
with bash 3.2 — because eventually it will.
The first decision is not a line of code. It is: which shell am I targeting? That choice decides what you are allowed to write. Make it before the shebang.
The header you start every bash script with
#!/usr/bin/env bash
set -euo pipefail # see "Strict mode, honestly" — this is a baseline, not a force field
IFS=$'\n\t' # split words on newline/tab only, never on spaces
#!/usr/bin/env bash— find bash onPATH; do not hardcode/bin/bash, which is 3.2 on macOS and may not exist on some images.set -e— exit on an uncaught non-zero command. Leaky (below), still worth having.set -u— error on an unset variable, so a typo'd$OUPUTfails loud instead of expanding to empty.set -o pipefail— a pipeline fails if any stage fails, not just the last. Bashism — not in POSIXsh.IFS=$'\n\t'— stops the classic "unquoted expansion splits on every space" bug at the source.
Pick your shell first
set -o pipefail, arrays, [[ ]], and local are bashisms. If your shebang
is #!/bin/sh you may not get bash — on Debian/Alpine sh is dash/busybox.
#!/usr/bin/env bash |
#!/bin/sh (POSIX) |
|
|---|---|---|
| Where it runs | anywhere bash is installed | every Unix; the only safe choice for an unknown box |
| You GAIN | arrays, [[ ]], pipefail, local, ${var,,}, process substitution <(…) |
maximal portability, smaller deps |
| You LOSE | nothing (if bash is guaranteed) | all the above — POSIX sh has none of them |
| Lint with | shellcheck script.sh |
shellcheck -s sh script.sh |
| Test with | bash script.sh |
dash script.sh |
What ships with it
4 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 1mo ago First seen · 228 lines · 82 tokens per session scan B 40f96d56c79d
bash-scripting is a skill published in the GitHub repository ericrisco/rsc-harness (225 stars, last pushed 2d ago), licensed MIT. It adds 82 tokens to every session and 2,937 once invoked, about $0.0003 per session on Opus 5.5. A static security scan graded it B with 2 findings (recursive force delete, makes network calls). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.
Other skills, from other repositories
shell-scripting
Use this skill when writing bash or zsh scripts, parsing arguments, handling errors, or automating CLI workflows. Triggers on bash scripting, shell scripts, argument parsing, process substitution, here documents, signal trapping, exit codes, and any task requiring portable shell script development.
shell-scripting
A guide to writing Bash shell scripts, which automate command-line tasks on Linux and similar systems. It covers variables, arrays, conditions, loops, functions, and safer script structure.
shell-bash
Shell scripting and Bash programming patterns.
mainframe
Discover MAINFRAME read-only shell helpers and route durable agent authority through its control plane when available.
mainframe
Pi shell policy, explicit task checkpoints, and runtime status. Use for Mainframe status, shell-policy questions, or resuming checkpointed project work.
bash-defensive-patterns
Master defensive Bash programming techniques for production-grade scripts. Use when writing robust shell scripts, CI/CD pipelines, or system utilities requiring fault tolerance and safety.