一键导入
shell-scripting
Best practices for writing shell scripts. Use when writing bash, sh, zsh, or other shell code for automation, scripting, or command-line tasks.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
菜单
Best practices for writing shell scripts. Use when writing bash, sh, zsh, or other shell code for automation, scripting, or command-line tasks.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
基于 SOC 职业分类
JavaScript development guidance for Claude Code. Use when writing, testing, or working with JavaScript code to ensure consistent practices and proper test execution.
Python coding conventions and best practices. Use when writing, reviewing, or refactoring Python code, or when working with Python scripts and projects.
| name | shell-scripting |
| description | Best practices for writing shell scripts. Use when writing bash, sh, zsh, or other shell code for automation, scripting, or command-line tasks. |
When writing shell scripts, prefer long options (e.g., --verbose) over short options (e.g., -v) for improved readability and maintainability.
Why long options?
grep --ignore-case is clearer than grep -iExample:
# Good: Clear and self-documenting
find /var/log --name "*.log" --type f --mtime +30 --delete
# Avoid: Requires knowledge of what each flag means
find /var/log -name "*.log" -type f -mtime +30 -delete
Exception: Short options are acceptable for:
ls -la)