Repository navigation
skills: teach git notes for debugging context on fix commits - #3940
Closed
RandyMcMillan wants to merge 2 commits into
Closed
RandyMcMillan wants to merge 2 commits into
RandyMcMillan wants to merge 2 commits into
Conversation
The repository-content-changes skill lands commits but says nothing about preserving the debugging story behind a fix. Add a section explaining why git notes are the right place for root cause and evidence (run ids), and how: the MCP tools cannot write refs/notes/commits, so the agent hands the user the add/push/fetch commands, and treats the notes ref as shared history that is never force-pushed casually.
Contributor
There was a problem hiding this comment.
🟡 Changes recommended
The documented sequence may fail because it creates the fix commit remotely without fetching it locally before running git notes add, causing an unknown-object error on a stale clone.
1 open issue
What changed in this PR
Updates the repository-content-changes bundled skill to preserve debugging context for remotely created fix commits using Git notes.
Changes:
- Documents recording root causes and workflow evidence with Git notes.
- Provides commands for adding, pushing, and fetching notes under
refs/notes/commits. - Explains that MCP tools cannot write notes directly and warns against casually force-pushing the shared notes ref.
| File | Description |
|---|---|
| pkg/skills/catalog/skills/repository-content-changes/SKILL.md | Adds Git notes workflow guidance for recording, publishing, and retrieving debugging context on fix commits. |
Review effort: Lite (adaptive)
Comment on lines
+86
to
+88
| - add: `git notes add -m "<context>" <sha>` | ||
| - push: `git push origin refs/notes/commits` | ||
| - fetch on a fresh clone: `git fetch origin refs/notes/commits:refs/notes/commits`, |
The fork's main predates the skills catalog, so this file reads as an add/add conflict against upstream. Removing it lets the update-branch merge apply cleanly; the change is re-applied on top afterwards.
Author
|
Superseded by #3941 — this branch was based on a stale fork |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

What
Adds a "Recording the why with git notes" section to the
repository-content-changesbundled skill.Closes #3939.
Why
Agents landing fix commits through this server produce a commit message but lose the debugging story — root cause, evidence (workflow run ids), why this fix. Git notes are the right home for that (
git log --notestells the whole story), but agents systematically mishandle them: notes live onrefs/notes/commits, which is neither pushed nor fetched by default, and no MCP tool here can write them.The guidance
git notes add -m "<context>" <sha>; push explicitly withgit push origin refs/notes/commits; fetch on fresh clones withgit fetch origin refs/notes/commits:refs/notes/commits(or one-time fetch refspec config)refs/notes/commitscasually — shared ref, treat like the default branchDocs-only change to one SKILL.md; no frontmatter, toolset instruction, or snapshot changes.
TestToolsetInstructionsAreCoveredBySkillsunaffected (instructions untouched).