file-tech-debt
Files a new tech-debt GitHub issue for an out-of-scope code-review finding. Builds the dedup key, skips an open orโฆ
Pulls the latest GAIA release into this project without clobbering customizations, with a three-way merge per file using .gaia/manifest.json classes. Trigger when the user clicks the statusline `๐ /update-gaia` indicator or asks "update GAIA", "pull the latest GAIA", "apply the
Claude Code
$ npx -y skills add gaia-harness/gaia --skill update-gaia --agent claude-code
Codex
$ npx skills add gaia-harness/gaia --skill update-gaia -a codex -y
Cursor
$ npx skills add gaia-harness/gaia --skill update-gaia -a cursor -y
Gemini CLI
$ npx skills add gaia-harness/gaia --skill update-gaia -a gemini-cli -y
GitHub Copilot
$ npx skills add gaia-harness/gaia --skill update-gaia -a github-copilot -y
OpenCode
$ npx skills add gaia-harness/gaia --skill update-gaia -a opencode -y
Windsurf
$ npx skills add gaia-harness/gaia --skill update-gaia -a windsurf -y
name: update-gaia description: Pulls the latest GAIA release into this project without clobbering customizations, with a three-way merge per file using .gaia/manifest.json classes. Trigger when the user clicks the statusline `๐ /update-gaia` indicator or asks "update GAIA", "pull the latest GAIA", "apply the new GAIA release".
Contents: Pre-flight: Worktree check; Pre-flight: Branch check (run modes); Step 1: Read baseline version; Step 2: Resolve latest release; Step 3: Compare versions (main checkout, worktree run in place); Pre-flight: Pull check (reads `references/pull-mode.md`); Pre-flight: Decision log check; Pre-flight: Claim check (reads `references/claim-flow.md`); Step 3b: Refuse a 1.x baseline; Step 3c: Download and verify the bundles; Step 3c2: Check the toolchain; Step 3d: Select migration notes; Step 4: Show the release notes and confirm (on Proceed: the update worktree, the worktree notice, the stop rule, the claim); Step 4b: Prune prior-run artifacts; Conflict flow (reads `references/conflict-flow.md`: dispatch, questions, decisions, follow-ups); Step 9b: Follow the after-merge notes; Step 9c: Carry new setup features (machine scope deferred to the post-merge cleanup); Step 9c2: Prune overbroad unowned entries; Step 9d: Record the update; Quality gate; Review point; Step 11 (orchestrator, after the review-point commit); Step 12: The leftover-file cleanup; Cost record (run end). Local runs (`--local <tarball>`) and recorded local builds: `references/local-bundle.md`, read at Step 1.
Pull the latest GAIA release into this project without clobbering customizations. Does a three-way comparison per file (adopter / baseline / latest) and respects explicit classes in `.gaia/manifest.json`:
The first three take the same Step 7 rows. The class changes only two of them: which status a clean overwrite reports (`owned` โ `overwrite`, the other two โ `merge`), and what happens when the release newly owns a path the adopter already has (`owned` backs up and overwrites, the other two fall through to the ordinary rows). Step 7 is authoritative.
Backups land in `.gaia-backup/<timestamp>/` in the acting tree, the update worktree. The merge report, its candidate files and the instruction snapshot land in the run directory, `<main checkout path>/.gaia/local/cache/shared/update-gaia/run` (gitignored, written only through Bash), which the run removes after Step 11.
**Who runs what.** This file runs the pre-flight through Step 4b, then dispatches the execution agent for Steps 6 to 9 (`references/merge-execution.md`), which merges and writes a JSON report but asks nothing. Every step after that runs here, in the orchestrator: the questions, applying the answers and recording the decisions, the follow-ups, Steps 9b to 9d, the quality gate, the review point with its single commit confirm, and Steps 11 and 12. Everything from Step 4b on runs inside the update worktree, so the main checkout's branch, files and `node_modules` stay as the user left them, whichever branch it holds. Every orchestrator step lives in this file or in `references/conflict-flow.md`, which the orchestrator reads in full before the dispatch, because the merge walk can overwrite this skill's own files partway through the run and the orchestrator keeps following the copy it already read. The draft PR's merge and cleanup run later, through the PR Merge Workflow.
Every command block below is one plain command with each value typed as a literal (written `<NAME>`), or a call to a tracked script by its literal path: inside a worktree session the runtime refuses a captured command substitution, a shell variable in a path, and a heredoc.
This wrapper changes `.gaia/VERSION` and opens a PR, which belong to the main checkout (the clone's primary working directory, on any branch) or to this command's own update worktree, never to a SPEC, debt or feature worktree or to `/update-deps`'s `deps/` worktree. Invoked from any other linked worktree, it refuses hard with a message that surfaces the cached version state from main, so the user knows whether a GAIA update is even pending. The `"update/"` argument admits a worktree on an `update/` branch, so a re-run inside this command's own update worktree continues there.
Detection (run this first, before anything else):
. .gaia/scripts/main-only-lib.sh . .gaia/scripts/update-state-line-lib.sh gaia_refuse_if_worktree "/update-gaia" gaia_update_gaia_state_line "update/" || exit 1
The state-line function lives in `update-state-line-lib.sh` rather than inline here because the runtime inspects a command's text: an inline definition holding captured substitutions would get this whole block refused on a re-run inside the own update worktree, before the guard could admit it.
git branch --show-current
Decide the run mode, in this order:
1. **Worktree run in place.** The branch starts `update/` and `bash .gaia/scripts/main-root-lib.sh --is-worktree` exits 0: a re-run inside this command's own update worktree. Read `<worktree path>` with `git rev-parse --show-toplevel` and `<main checkout path>` with `bash .gaia/scripts/main-root-lib.sh`, each carried as a literal. No worktree is created. Set `WORKTREE_RUN=true`, `CREATED_WORKTREE=false`, `SHOULD_CREATE_WORKTREE=false`. Wait for provisioning now with `bash <main checkout
Claude is raw power. GAIA is order and focus. A serious harness for Claude Code. It keeps Claude-shipped code production-grade as your team scales. The React frontend is handled. You build the rest of your app on top.
Files a new tech-debt GitHub issue for an out-of-scope code-review finding. Builds the dedup key, skips an open orโฆ
Runs GAIA wiki maintenance (sync, consolidate, lint with fixes) in one command and lands it as one commit and PR. Trigger onโฆ
Applies descriptive, self-documenting naming in any language (TypeScript, bash, workflow YAML, Dockerfiles). Use this skillโฆ
Maintainer-only. Rewrites a version's GAIA CHANGELOG entries as plain-language public release notes for the marketing siteโฆ
Runs test-driven development with a red-green-refactor loop, an opt-in tool for logic where test-first helps. Use when the userโฆ
Remediates dependencies in place of Dependabot version and security updates. Discovers outdated packages and open securityโฆ
You MUST use this before any creative work - creating features, building components, adding functionality, modifying behavior, orโฆ
Ask which skill or flow fits your situation. A router over the skills in this repo.