跳到正文
cccskills
免费在 GitHub 公开

pump-shell-scripts

Production-quality Bash scripts for Solana vanity generation, keypair verification, batch operations, dependency auditing, and test orchestration — with security-hardened patterns including file permissions, input validation, and cleanup traps.

中文简介正在准备中。当前显示原文说明。

查看安装方法

包含的文件(1)

  • SKILL.md2.8 KB

SKILL.md(原文)

安装前可以查看交给 AI 代理的指令内容。

Shell Scripting & CLI Tools — Production Bash Scripts

Production-quality Bash scripts for vanity generation, keypair verification, batch operations, dependency auditing, and test orchestration with security-hardened patterns.

Scripts Overview

ScriptPurpose
scripts/utils.shShared library (colors, logging, validation, cleanup)
scripts/generate-vanity.shVanity address generation via solana-keygen
scripts/batch-generate.shParallel batch generation
scripts/verify-keypair.sh7-point keypair verification
scripts/test-rust.sh10-step Rust test orchestration
tools/audit-dependencies.shDependency security audit
tools/check-file-permissions.shFile permission validation
tools/verify-keypair.tsTypeScript 9-point verifier

Keypair Verification (7 Points)

verify_keypair() {
    # 1. File exists
    # 2. Valid JSON array
    # 3. Exactly 64 bytes
    # 4. File permissions are 0600
    # 5. solana-keygen verify passes
    # 6. Public key matches filename
    # 7. Re-derive public key from secret matches
}

Security Patterns

# Cleanup trap
trap 'cleanup_temp_files' EXIT ERR INT TERM

# File permissions
chmod 600 "$keypair_file"

# Input validation
validate_base58() {
    [[ "$1" =~ ^[1-9A-HJ-NP-Za-km-z]+$ ]] || die "Invalid Base58"
}

# No shell injection
# Use "$var" (quoted) everywhere, never $var

Makefile Integration

TargetDescription
make test-rustRun Rust test suite
make benchRun Criterion benchmarks
make generateGenerate a vanity address
make verifyVerify a keypair file
make auditAudit dependencies

Patterns to Follow

  • Source scripts/utils.sh in all scripts for shared utilities
  • Use set -euo pipefail at the top of every script
  • Quote all variable expansions: "$var" not $var
  • Use trap for cleanup of temporary files
  • Validate all user input (Base58, paths, integers)
  • Set chmod 600 on any keypair file immediately after creation

Common Pitfalls

  • solana-keygen verify expects the address as the first argument, not the file
  • shred is not available on all systems — check with command -v
  • mktemp patterns differ between macOS and Linux
  • read -r is essential to prevent backslash interpretation
  • Always use [[ ]] over [ ] for conditionals

评价

还没有评价。欢迎分享你的使用感受。

评论

无需登录即可发表。欢迎分享使用感受、提问,或说明在哪些环境下无法运行。

还没有评论。来写第一条吧。

提交后会立即公开。请勿填写邮箱、电话等个人信息。URL 最多 2 个。

0 / 1000 字

此表单受 reCAPTCHA 保护,适用 Google 的隐私权政策和服务条款。

同一仓库的技能

1password

免费

Set up and use 1Password CLI (op). Use when installing the CLI, enabling desktop app integration, signing in (single or multi-account), or reading/injecting/running secrets via op.

中文简介正在准备中。当前显示原文说明。

x402agent/SolanaOS92026年7月23日 更新

Manage Apple Notes via the `memo` CLI on macOS (create, view, edit, delete, search, move, and export notes). Use when a user asks SolanaOS to add a note, list notes, search notes, or manage note folders.

中文简介正在准备中。当前显示原文说明。

x402agent/SolanaOS92026年7月23日 更新

Manage Apple Reminders via remindctl CLI (list, add, edit, complete, delete). Supports lists, date filters, and JSON/plain output.

中文简介正在准备中。当前显示原文说明。

x402agent/SolanaOS92026年7月23日 更新

Create, search, and manage Bear notes via grizzly CLI.

中文简介正在准备中。当前显示原文说明。

x402agent/SolanaOS92026年7月23日 更新

Monitor blogs and RSS/Atom feeds for updates using the blogwatcher CLI.

中文简介正在准备中。当前显示原文说明。

x402agent/SolanaOS92026年7月23日 更新

blucli

免费

BluOS CLI (blu) for discovery, playback, grouping, and volume.

中文简介正在准备中。当前显示原文说明。

x402agent/SolanaOS92026年7月23日 更新

查看 x402agent 的全部技能

报告此技能的问题