$npx -y skills add zubair-trabzada/geo-seo-claude --skill geo-updatePull the latest GEO-SEO skill updates from the upstream repository. Compares installed files against the latest release, shows what changed, and updates all skills, agents, scripts, and schema templates in place.
| 1 | # GEO-SEO Update Skill |
| 2 | |
| 3 | ## Purpose |
| 4 | |
| 5 | Updates the locally installed GEO-SEO skills, agents, scripts, and schema templates to the latest version from the upstream repository. Shows a summary of what changed before and after the update. |
| 6 | |
| 7 | --- |
| 8 | |
| 9 | ## Update Workflow |
| 10 | |
| 11 | ### Step 1: Determine Installed Location |
| 12 | |
| 13 | The GEO-SEO toolkit installs to these locations under `~/.claude/`: |
| 14 | |
| 15 | | Component | Install Path | |
| 16 | |-----------|-------------| |
| 17 | | Main skill | `~/.claude/skills/geo/` | |
| 18 | | Sub-skills | `~/.claude/skills/geo-*/` | |
| 19 | | Agents | `~/.claude/agents/geo-*.md` | |
| 20 | | Scripts | `~/.claude/skills/geo/scripts/` | |
| 21 | | Schema templates | `~/.claude/skills/geo/schema/` | |
| 22 | | Hooks | `~/.claude/skills/geo/hooks/` | |
| 23 | |
| 24 | Verify the installation exists by checking for `~/.claude/skills/geo/SKILL.md`. If it does not exist, inform the user that GEO-SEO is not installed and suggest running the installer instead. |
| 25 | |
| 26 | ### Step 2: Clone Latest from Upstream |
| 27 | |
| 28 | ```bash |
| 29 | TEMP_DIR=$(mktemp -d) |
| 30 | git clone --depth 1 https://github.com/zubair-trabzada/geo-seo-claude.git "$TEMP_DIR/repo" |
| 31 | ``` |
| 32 | |
| 33 | If the clone fails, report the error and stop. Do not modify any installed files. |
| 34 | |
| 35 | ### Step 3: Compare Installed vs Latest |
| 36 | |
| 37 | Before copying files, generate a diff summary so the user knows what will change: |
| 38 | |
| 39 | 1. For each component directory, compare the installed files against the cloned files using `diff --recursive --brief`. |
| 40 | 2. Categorise changes as: |
| 41 | - **New files** — exist in upstream but not locally |
| 42 | - **Modified files** — exist in both but differ |
| 43 | - **Removed files** — exist locally but not in upstream (these are NOT deleted automatically) |
| 44 | 3. Present the summary to the user. |
| 45 | |
| 46 | ### Step 4: Apply Updates |
| 47 | |
| 48 | Copy files from the cloned repo over the installed locations: |
| 49 | |
| 50 | ```bash |
| 51 | CLAUDE_DIR="${HOME}/.claude" |
| 52 | SOURCE_DIR="$TEMP_DIR/repo" |
| 53 | |
| 54 | # Main skill |
| 55 | cp -r "$SOURCE_DIR/geo/"* "$CLAUDE_DIR/skills/geo/" |
| 56 | |
| 57 | # Sub-skills |
| 58 | for skill_dir in "$SOURCE_DIR/skills"/*/; do |
| 59 | skill_name=$(basename "$skill_dir") |
| 60 | mkdir -p "$CLAUDE_DIR/skills/${skill_name}" |
| 61 | cp -r "$skill_dir"* "$CLAUDE_DIR/skills/${skill_name}/" |
| 62 | done |
| 63 | |
| 64 | # Agents |
| 65 | for agent_file in "$SOURCE_DIR/agents/"*.md; do |
| 66 | cp "$agent_file" "$CLAUDE_DIR/agents/" |
| 67 | done |
| 68 | |
| 69 | # Scripts |
| 70 | if [ -d "$SOURCE_DIR/scripts" ]; then |
| 71 | cp -r "$SOURCE_DIR/scripts/"* "$CLAUDE_DIR/skills/geo/scripts/" |
| 72 | chmod +x "$CLAUDE_DIR/skills/geo/scripts/"*.py 2>/dev/null || true |
| 73 | fi |
| 74 | |
| 75 | # Schema templates |
| 76 | if [ -d "$SOURCE_DIR/schema" ]; then |
| 77 | cp -r "$SOURCE_DIR/schema/"* "$CLAUDE_DIR/skills/geo/schema/" |
| 78 | fi |
| 79 | |
| 80 | # Hooks |
| 81 | if [ -d "$SOURCE_DIR/hooks" ] && [ "$(ls -A "$SOURCE_DIR/hooks" 2>/dev/null)" ]; then |
| 82 | mkdir -p "$CLAUDE_DIR/skills/geo/hooks" |
| 83 | cp -r "$SOURCE_DIR/hooks/"* "$CLAUDE_DIR/skills/geo/hooks/" |
| 84 | chmod +x "$CLAUDE_DIR/skills/geo/hooks/"* 2>/dev/null || true |
| 85 | fi |
| 86 | ``` |
| 87 | |
| 88 | ### Step 5: Update Python Dependencies |
| 89 | |
| 90 | If `requirements.txt` exists in the upstream repo and differs from the installed version: |
| 91 | |
| 92 | ```bash |
| 93 | python3 -m pip install -r "$SOURCE_DIR/requirements.txt" --quiet |
| 94 | ``` |
| 95 | |
| 96 | Report any failures but do not treat them as fatal. |
| 97 | |
| 98 | ### Step 6: Clean Up |
| 99 | |
| 100 | ```bash |
| 101 | rm -rf "$TEMP_DIR" |
| 102 | ``` |
| 103 | |
| 104 | ### Step 7: Report Results |
| 105 | |
| 106 | Present a summary: |
| 107 | |
| 108 | ``` |
| 109 | GEO-SEO Update Complete |
| 110 | ======================= |
| 111 | New files: [count] |
| 112 | Modified files: [count] |
| 113 | Unchanged: [count] |
| 114 | Removed upstream (kept locally): [count] |
| 115 | |
| 116 | Dependencies: [updated / unchanged / failed] |
| 117 | ``` |
| 118 | |
| 119 | If there were removed files upstream, list them and suggest the user review whether to delete them manually. |
| 120 | |
| 121 | --- |
| 122 | |
| 123 | ## Important Notes |
| 124 | |
| 125 | - **Never delete locally installed files** that no longer exist upstream. The user may have customised them. List them and let the user decide. |
| 126 | - **Never modify `~/.claude/settings.json` or `~/.claude/settings.local.json`** — these are user configuration files, not part of the GEO-SEO toolkit. |
| 127 | - **If already up to date** (no diff), report that and skip the copy step. |
| 128 | - **Restart notice:** Remind the user that skill changes take effect in new Claude Code sessions. They should restart their session to use the updated skills. |