From 518b450d64c2cf9c8192d506baed54d8dd0cbb4d Mon Sep 17 00:00:00 2001 From: Garry Tan Date: Sun, 22 Mar 2026 14:43:24 -0700 Subject: [PATCH] fix: skip sidecar dir in Codex skill linking (#269) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Adds guard to skip .agents/skills/gstack in link_codex_skill_dirs() — it's a runtime asset sidecar, not a standalone skill. Prevents duplicate skill discovery and symlink overwriting. Fixes #261 Co-authored-by: mvanhorn Co-Authored-By: Claude Opus 4.6 (1M context) --- setup | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/setup b/setup index d67bdec1..bb423607 100755 --- a/setup +++ b/setup @@ -173,6 +173,10 @@ link_codex_skill_dirs() { for skill_dir in "$agents_dir"/gstack*/; do if [ -f "$skill_dir/SKILL.md" ]; then skill_name="$(basename "$skill_dir")" + # Skip the sidecar directory — it contains runtime asset symlinks (bin/, + # browse/), not a skill. Linking it would overwrite the root gstack + # symlink that Step 5 already pointed at the repo root. + [ "$skill_name" = "gstack" ] && continue target="$skills_dir/$skill_name" # Create or update symlink if [ -L "$target" ] || [ ! -e "$target" ]; then