dbs-install-skill
Installs a single Skill or a collection of Skills to universal Agents, Claude Code, Codex, WorkBuddy, Grok, Hermes Agent, Kiro, Qwen Code, Cline, and other agents. Use when users request cross-agent installation, synchronization, inspection, deduplication, or uninstallation of Skills.
1How It Works & Mechanism
SKILL.md itself serves merely as a layer of "protocol specification + output guidelines", delegating actual installation operations to the built-in bash script; users always run the same single command, while the script automatically detects the host type and target entry points internally.
用户始终使用同一条命令。脚本自动选择公共入口或专属入口,用户无需判断宿主类型,也无需添加模式参数。
The routing strategy follows a "single shared entry point first" principle: all Skills are first linked to ~/.agents/skills, and dedicated directories are provisioned only for hosts that have not yet adopted this convention, provided their home directory already exists.
以下客户端当前仍使用专属目录。只有对应主目录已经存在时,脚本才创建链接:
The script centrally locates all host root directories using the INSTALL_HOME variable, which defaults to $HOME and can be overridden via DBS_INSTALL_HOME (facilitating testing and sandboxing).
INSTALL_HOME="${DBS_INSTALL_HOME:-$HOME}"
The actual persistence mechanism uses symbolic links (Unix) or directory junctions (Windows) without copying source files, ensuring immediate synchronization across all hosts whenever the source Skill is updated.
Unix-like 系统使用符号链接;Windows 的 Bash/MSYS 环境使用目录 Junction,避免 `ln -s` 在部分配置下生成实体目录副本。
Grok employs a "thin adapter layer" instead of symlinks: the script generates a minimal SKILL.md with user_invocable: true in the frontmatter, containing only a "Source of truth" line pointing back to the true source.
- Source of truth: $src/SKILL.md
The Skill name is derived from the name field in the true source's SKILL.md frontmatter rather than the directory name (parsed using awk restricted to the frontmatter section), enabling source directories to include category prefixes while maintaining stable trigger names across Agents.
入口名优先读取真源 `SKILL.md` frontmatter 中的 `name`;只有 `name` 缺失时才退回源目录名。这样源目录可以使用分类前缀,各 Agent 仍保持稳定的历史触发名。
Every link operation performs an idempotent cleanup concurrently: removes redundant/historical aliases/broken links pointing to the same true source while preserving real directories and links pointing to other sources (conflicts are reported).
删除公共入口兼容客户端专属目录中指向同一真源的冗余链接;
The status action translates "the presence of redundant entry points" into deterministic exit code semantics: outputs ✓ only when no redundancy is found, and reports ✗ with a failure exit code when redundancy exists.
状态正常时,脚本必须输出:
2Core Capabilities
4Recommended Governance & Evidence
- scripts/: Local script or command execution: skills/dbs-install-skill/scripts/install-skill.sh (bash, executed directly by the model per SKILL.md instructions)
- 环境变量 / API Key: Vendor service key reads: Reads $HOME and $DBS_INSTALL_HOME to locate Agent root directories (INSTALL_HOME="${DBS_INSTALL_HOM)
- 本地工作目录: File I/O and artifact output: Symlinks/Junctions under ~/.agents/skills/<name> and 6 dedicated host directories (mkdir -p target directory)
5Second-Pass Verification
- [ok] 外部资源/工具:是否存在未披露的网络或第三方依赖 — skills/dbs-install-skill 整目录(SKILL.md + install-skill.sh + windows-junction.ps1 + agents/openai.yaml)token 扫描 curl/wget/https?:///api_key/token/secret/fetch 全部零命中;脚本只调用 ln/mkdir/rm/find/awk/sed/uname/dirname/basename 与(Windows 时)pwsh/powershell,均为本机命令。external_deps 记为空数组成立。
- [ok] 安全结论:删除动作是否会危及用户既有文件 — unlink 路径只走 unlink_if_points_to(先比对链接目标是否等于本次真源)与 unlink_grok_one;Grok 分支的 rm -rf 前面有两道门:is_managed_link、或以 grep -q '^## Grok Bridge$' 判定为本工具生成的桥接文件,否则打印「✗ 是真实目录或文件,已保留」并 return 2。link 路径同理(link_one 遇 -e "$link" 即保留)。未发现无条件 rm -rf。
- [discrepancy] SKILL.md 自检项「private/ 与 .private/ 没有被读取、复制、暂存或安装」是否由脚本兑现 — 该句仅出现在 skills/dbs-install-skill/SKILL.md:203;对整个 skill 目录 grep -rni private 只此一处,install-skill.sh 与 windows-junction.ps1 中均无任何 private/.private 过滤或跳过逻辑,仓库工具层 tools/test-dbs-install-skill*.sh 也无相关用例。真实行为是:脚本对源目录建链接/桥接,既不复制也不过滤子目录,因此源 Skill 目录内若存在 private/,它会随源目录一起被 Agent 目录侧访问到(不会产生副本)。该项属文档声明超前于实现,不构成凭空夸大宣传,但「没有被读取/安装」这一表述在脚本层面无证据。
- [ok] 功能声明 vs 实际代码能力:SKILL.md 描述的宿主清单与脚本数组是否一致 — SKILL.md 专属入口列 6 家(Claude Code/WorkBuddy/Hermes Agent/Kiro/Qwen Code/Cline),对应 NATIVE_TARGET_DIRS 恰好 6 项;公共兼容客户端列 8 家(Codex/GitHub Copilot/Gemini CLI/Cursor/Augment/Roo Code/OpenCode/OpenHands),对应 REDUNDANT_TARGET_DIRS 前 8 项注释「前 8 项已能读取 ~/.agents/skills」,数组实际长度 24(其余为旧版目录,仅用于清理)。一致。
- [unlocatable] 证据定位:stars/last_push/license 是否能在 pin 源码内定位 — stars=10121、last_push=2026-09-07 取自站点池 data/pool.json 的机器采集字段(GitHub API),pin 工作副本为本地镜像,源码内无此数据,无法在用 read 可及的仓库文件内逐字命中;license 可在仓库根 LICENSE 逐字命中(CC BY-NC 4.0)。
6Verdict & Scenarios
d04f021c0c5317a1…