global-rules

v2026.09.24

Global safety and operational rules for opencode sessions. Auto-loaded with highest priority on every session. Contains critical rules learned from incidents to prevent system crashes and data loss.

GitHub
安装命令
npx skhub add cycleuser/global-rules
Markdown
SKILL.md

Safety Rules

Critical: Read and follow all rules in this directory for every bash/command execution.

Core rules:

  1. Always set explicit timeout on bash calls — 30s for tests, 60s for installs, never default
  2. Never run unscoped full test suites — use -k or file paths to limit scope
  3. Never use rm -rf without variable guards, curl|bash, sudo, or kill -9
  4. Infinite loops must have hard timeout + budget limits — no unbounded while(True)
  5. Redirect stdin with < /dev/null for non-interactive commands

Rules

Incident Record

DateIncidentRoot CausePrevention
2026-05-08opencode TUI crashbash timeout → SIGKILL → stdin FD corrupted → setRawMode errno: 9Always set explicit timeout; never SIGKILL

See Also

  • /安检 from an-jian — Security audit for dangerous patterns
  • /skills from skill-manager — Browse all installed skills
发现
标签

此技能尚未发布标签。

版本
最新版本元数据

版本

v2026.09.24

发布时间

Sep 24, 2026

分类

未分类

许可证

GPL-3.0

源路径

skills/global-rules

默认分支

main

最新提交

d57a35e

Tree SHA

02d9442