shell-scripting

shell-scripting is a skill for Claude Code from cass-2003/local-workflow-skill. It costs 45 tokens per session (2,366 once invoked), scanned A, original, MIT.

A guide to writing reliable Bash and PowerShell scripts for automating computer tasks. It covers choosing the right shell, handling arguments and errors, and checking scripts before running them.

In plain words
What is it for?
Use it for deployment helpers, file and system automation, command-line tools, and cross-platform scripts on Linux, macOS, Windows, or CI systems.
Why use it?
It reduces failures caused by unexpected input, missing permissions, portability differences, or ignored errors. It also gives a consistent way to inspect and verify automation scripts.

Skill for Claude Code

Written for Claude Code: disable-model-invocation in frontmatter. Also seen: positional $N argument.

Good fit Use it for deployment helpers, file and system automation, command-line tools, and cross-platform scripts on Linux, macOS, Windows, or CI systems.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/cass-2003/local-workflow-skill/shell-scripting
Install

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.

Any agent
npx skills add cass-2003/local-workflow-skill --skill shell-scripting
Clone the repo
git clone --depth 1 https://github.com/cass-2003/local-workflow-skill

Made for: Claude Code.

Wrote 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.

agentmods badge for shell-scripting

README.md
[![agentmods](https://agentmods.dev/badge/skills/cass-2003/local-workflow-skill/shell-scripting/github.svg)](https://agentmods.dev/skills/cass-2003/local-workflow-skill/shell-scripting)
Your own site
<a href="https://agentmods.dev/skills/cass-2003/local-workflow-skill/shell-scripting"><img src="https://agentmods.dev/badge/skills/cass-2003/local-workflow-skill/shell-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.

agentmods 80×15 button for shell-scripting

Your own site · 80×15
<a href="https://agentmods.dev/skills/cass-2003/local-workflow-skill/shell-scripting"><img src="https://agentmods.dev/badge/skills/cass-2003/local-workflow-skill/shell-scripting.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 45 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 2,366 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 1 finding. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

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.

ModelPer sessionOnce invoked
Fable 5.1 $0.00045 $0.02366
Opus 5 $0.00023 $0.01183
Sonnet 5 $0.00009 $0.00473
Haiku 4.5 $0.00005 $0.00237

Measured 6d ago against content hash 7f9115c88cac, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-10, from the pricing page.

Security

Grade A, and why

shell-scripting scanned grade A with 1 finding 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 6d 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.

Makes network callslowCapability

Not a fault in itself. Listed so you know the mod talks to something, and to what.

| HTTP 请求 | `curl -s` | `Invoke-RestMethod` |
skills/engineering-core/codex/shell-scripting/SKILL.md · 282 lines

How it starts

The opening of the file, as written. The whole thing — 282 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Shell Scripting

角色定义

你是 Shell 脚本专家,精通 Bash/PowerShell 自动化。目标:编写健壮、可移植的自动化脚本。

行为指令

  1. 确认环境: Bash 还是 PowerShell?目标平台?
  2. 读取现有脚本: 了解项目中的脚本风格和依赖
  3. 编写: 严格模式 + 参数解析 + 错误处理 + 日志
  4. 验证: shellcheck / bash -n / PowerShell PSScriptAnalyzer
  5. 测试: 边界情况(空输入、特殊字符、权限不足)

工具策略

任务 首选工具 备选
读取脚本 Read
编辑脚本 Edit
运行脚本 Bash
检查语法 Bash shellcheck / bash -n

决策树

平台?
├── Linux/macOS/Git Bash
│   ├── 简单任务 → 纯 Bash + coreutils
│   ├── 文本处理 → awk/sed/jq
│   ├── 并发 → xargs -P / GNU parallel / &+wait
│   ├── 复杂逻辑 → 考虑 Python
│   └── 交互式 → fzf + read
├── Windows (PowerShell 7+)
│   ├── 系统管理 → Get-/Set- cmdlets
│   ├── AD 操作 → ActiveDirectory 模块
│   ├── 远程 → Invoke-Command / Enter-PSSession
│   └── 对象处理 → Pipeline + Where-Object/Select-Object
└── 跨平台
    ├── PowerShell 7 (pwsh) — 推荐
    └── Python — 复杂逻辑

Bash 模板

#!/usr/bin/env bash
set -euo pipefail

readonly SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
readonly RED='\033[0;31m' GREEN='\033[0;32m' YELLOW='\033[1;33m' NC='\033[0m'

log_info()  { printf "${GREEN}[+]${NC} %s\n" "$1"; }
log_warn()  { printf "${YELLOW}[!]${NC} %s\n" "$1" >&2; }
log_error() { printf "${RED}[-]${NC} %s\n" "$1" >&2; }
die()       { log_error "$1"; exit 1; }

usage() {
    cat <<EOF
Usage: $(basename "$0") [OPTIONS] <target>

Options:
  -p, --port PORT    Port number (default: 80)
  -t, --threads N    Thread count (default: 10)
  -v, --verbose      Verbose output
  -h, --help         Show this help
EOF
    exit "${1:-0}"
}

PORT=80; THREADS=10; VERBOSE=false; TARGET=""
while [[ $# -gt 0 ]]; do
    case $1 in
        -p|--port)    PORT="$2"; shift 2 ;;
        -t|--threads) THREADS="$2"; shift 2 ;;
        -v|--verbose) VERBOSE=true; shift ;;
        -h|--help)    usage 0 ;;
        -*)           die "Unknown option: $1" ;;
        *)            TARGET="$1"; shift ;;
    esac
done
[[ -z "$TARGET" ]] && usage 1

main() {
    log_info "Processing $TARGET:$PORT (threads=$THREADS)"
}

main "$@"

Read the full file on GitHub · 282 lines

Changes

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.

  1. 6d ago First seen · 282 lines · 45 tokens per session scan A 7f9115c88cac

Subscribe to this mod's changes

shell-scripting is a skill published in the GitHub repository cass-2003/local-workflow-skill (12 stars, last pushed 2mo ago), licensed MIT. It adds 45 tokens to every session and 2,366 once invoked, about $0.0002 per session on Opus 5. A static security scan graded it A with 1 finding (makes network calls). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-03.

Related

Other skills, from other repositories

import-prom-rule

Bulk import of a Prometheus alert rule YAML file (create a whole set of rules at once). Dedicated to handling a remote URL or local YAML text, automatically parsing the three formats groups / a plain rules array / a single rule. ⚠️ Do not use this skill for single-rule creation — when the user describes a single alert…

ccfos/nightingale · 125 tokens

chinese-git-workflow

A reference for configuring Git with Chinese code-hosting services such as Gitee, Coding.net, GitLab China, and CNB, including SSH, HTTPS, credentials, CI, and repository mirroring.

jnMetaCode/superpowers-zh · 69 tokens

configure-env-variables

Configures environment variables for Power Pages site settings to support ALM across environments. Creates environment variable definitions in Dataverse, guides the user through linking site settings to those variables via the Power Pages Management app, adds the variables to the solution, and generates a…

microsoft/power-platform-skills · 119 tokens

atmos-profiles

Atmos profiles: profile directories, --profile and ATMOSPROFILE activation, profile merge behavior, environment switching, and routing profile-specific auth/toolchain/config overrides.

cloudposse/atmos · 35 tokens

webhook-management

Configure and validate CCAM webhook targets across supported chat, incident, automation, and generic providers. Use when listing provider requirements, creating or updating a target, scoping it to alert rules, sending a test notification, reviewing delivery history, or deleting a target.

hoangsonww/Claude-Code-Agent-Monitor · 56 tokens

monorepo-management

Master monorepo management with Turborepo, Nx, and pnpm workspaces to build efficient, scalable multi-package repositories with optimized builds and dependency management. Use when setting up monorepos, optimizing builds, or managing shared dependencies.

wshobson/agents · 54 tokens