Merge git-context into os-git and delete the commit_context fork #1591
Labels
No labels
P0
P1
P2
P3
bug
category/code-change
category/cross-repo
category/eval-run
category/investigation
category/no-test-target
category/owner-ruling
category/prose-artifact
category/recurring-chore
category/structure
category/umbrella
crc-refactor
create
delete
enhancement
filed-by/agent
filed-by/user
frozen
lint-rule
needs-info
needs-triage
next
plugin/cc-architect
plugin/os
plugin/os-adr
plugin/os-aidd-lint
plugin/os-backlog
plugin/os-context
plugin/os-doc-hygiene
plugin/os-sdlc
plugin/os-vault
project/cc-os
ready-for-agent
ready-for-human
recurring
review
rule-proposal
update
waiting
wayfinder:grilling
wayfinder:map
wayfinder:map
wayfinder:research
wayfinder:task
wayfinder:task
wontfix
worklist/deviations
worklist/lint-rule
worklist/new-implement-build
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
jared/cc-os#1591
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Problem
ruby-gems/git-context(gem 0.4.0, classGitContext::Git) andcc-plugins/git-context(agents that call its CLI) are a fourth git wrapper.ruby-gems/airtable-api/tools/commit_contextholds a read-only fork ofGitContext::Git. Two commit models exist:commit --only -- <paths>in os-sdlc, and "stage one path, commit what is staged" in git-context.Design:
docs/os-git/use-cases-and-domain.md(design) anddocs/os-git/call-site-checklist.md(call sites). Settled decisions are in design section 1 (docs/os-git/use-cases-and-domain.md): the gem lives inplugins/os-gitwith apath:source;git-contextandos:worktreemerge intoos-git; old wrappers go only after all references are updated; design order is use-cases, objects, interfaces;os-contextandos-vaultbecome Ruby; ticket tracking stays out ofos-git.Reproduce
n/a: structural move. Call sites: rows G-067 to G-072, G-117, G-118 in the checklist.
Approach
Move the git-context CLI commands
commit,commit-apply,repo-init, andrepo-auditintoplugins/os-git. Build them onOsGit::Repository,ChangeSet,History, andCommit::Plan. Apply the Q4 ruling (#1585):commit --onlyis the only commit mode.commit-applytakes path arguments (--path). Keep the refusals that the gem has today: blank message, empty commit, no-a. Do not move thegh repo createandtea repos createcalls inrepo_init/command.rbandworkspace.rb(they are host API work and out of scope; keep them as a proposal step).Keep the old CLI name
git-contextworking until every reference is updated: thegit-contextagents (commit.md,repo-init.md), theos-doc-hygieneclean skill (git-context commit-apply, row G-115, owned by the prompt-text ticket #1605), andplugins/os/skills/wrap/SKILL.md(git-context:commit). Skill names followplugins/cc-architect/references/conventions/cc-os-naming.md. After all references move, the retirement ticket (#1607) deletes the old plugin and gem.Rows to mark: G-067 to G-072, G-117, G-118, and the test rows G-188 to G-191.
Required work:
os-gitcommandscommit,commit-apply,repo-init,repo-audit— check: presentcommit-applyinplugins/os-git/bin/os-gitcommit-applyaccepts--pathand refuses a blank message and an empty commit — check: present--pathinplugins/os-git/lib/os_git/cli/commit_apply.rbMove the context sections (status, staged and unstaged diff, recent log, file history, untracked files) and the audit sections (gitignore gaps, tracked secrets, missing standard files) onto
Repositorymessages.commit-applykeeps the gem's message sources (--message,--message-file,--message-stdin) and its--jsonreport, and--allow-emptyreaches a Repository message.Orchestrator work, outside this worktree, after the merge: update the
cc-plugins/git-contextagents in that repository (AC 6), and deleteruby-gems/airtable-api/tools/commit_contextin that repository after its references are gone. Each commits in its own repository with explicit paths.plugins/os/skills/wrap/SKILL.mdmoves in #1605. The orchestrator marks the checklist rows (AC 8).Acceptance criteria
commit-apply --path a.rb --message "x"runs, then the commit holds onlya.rb.commit-applyruns, then it exits 2 and commits nothing.commit-applyruns, then it exits 1 and commits nothing (unless--allow-emptyis given).repo-init --dry-run --jsonruns, then it prints the same JSON actions and proposals as the gem did.repo-auditruns, then it reports the same gitignore gaps, tracked secrets, and missing standard files as the gem did.git-contextagents incc-plugins, when they are read after the orchestrator work, then they callos-gitcommands, and the no-attribution rule stays in the agent prompts (no regex guard in code). This criterion is verified by the orchestrator, not by a test.GitContext::GitandCommitContext::Git, when the tree is searched, then neither is called by any non-test file inplugins/os-git.- [x]withReplaced byfilled in. The orchestrator does this.commitruns, then its context sections hold the same content as the gem's sections, built onRepositoryandHistorymessages.Owner sketch
Non-goals
Host API calls (
gh,tea). Deleting the old gem and plugin (the retirement ticket #1607).Blocking edges
Blocked by the core ticket (#1588) and the ADR ticket (#1585).
Origin
Work started on branch ticket-1591.
Resolution
Done: git-context commands now run as bin/os-git on OsGit::Cli: commit, commit-apply --path, repo-init, repo-audit. cc-plugins git-context agents call os-git (9df6794). The commit_context fork is deleted; it was untracked in airtable-api. Rows marked. Pipeline run 252 ended verdict:error at contract audit; hand-finished with a fix list and one design audit.
Evidence: Merge
ed6d75ca(293eb325). os-git suite 359 runs, 0 failures; rubocop 117 files clean; smoke run through ~/.claude/plugins/os-git/bin/os-git of delete, rename, nothing to commit, and hook stderr.Follow-ups: none for this ticket: os-doc-hygiene and wrap text move in #1605; the gem stays until then. --yes dropped by design (rulings row 76); os-git bin not confirmed on PATH, so agents use the absolute path.