/repomatic:upstream-audit [audit|init|refresh|sync-git]from Repomatic
Creates or updates docs/upstream.md tracking a project's contributions back to its dependencies: merged PRs, reported issues, workarounds, and declined features.
Ships in Repomatic. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
None: SKILL.md is the whole skill.
![ -f pyproject.toml ] && grep '^name' pyproject.toml | head -1 || echo "No pyproject.toml"
!git config user.name 2>/dev/null || echo "No git user"
!gh api /user --jq '.login' 2>/dev/null || echo "No gh auth"
![ -f docs/upstream.md ] && grep '^## ' docs/upstream.md || echo "No docs/upstream.md yet"
![ -f docs/upstream.md ] && grep -c 'github.com/' docs/upstream.md || echo 0
You create and maintain docs/upstream.md, which tracks the project's relationship with its upstream dependencies: code contributed back, workarounds provided, issues reported, and features declined.
Fetch this file as reference when building or auditing an upstream page:
kdeldycke/click-extra/docs/upstream.md: tracks merged PRs across Click, python-tabulate, Pygments, Furo, Cloup, and click-contrib projects, plus upstreamed workarounds, feature-area-grouped workarounds still in place, declined PRs, and open upstream issues.The page uses five sections:
Items are listed as markdown links: - [`#N` - Title](url)
A merged, fixed or declined item is that link alone. Add prose only for what the thread lacks, like a workaround still in place. A comment on another person's thread also keeps one line that says what the comment reports.
audit (default): Check status of all linked issues/PRs in an existing page and report items that need to move between sections.init: Create docs/upstream.md from scratch by discovering all upstream contributions.refresh: Same as audit, but also apply the changes.sync-git: Scan the git log for upstream references not yet in the document.init)Determine the GitHub username from gh api /user --jq '.login' or git config user.name. Confirm with the user.
Extract dependencies from pyproject.toml (both [project.dependencies] and [project.optional-dependencies]/[dependency-groups]). For each dependency, find its GitHub repository:
Project-URL metadata of the installed package: uv run --frozen python -c "from importlib.metadata import metadata; print(metadata('<pkg>').get_all('Project-URL'))". Or read https://pypi.org/pypi/<pkg>/json.source table of uv.lock. A package from an index records only that index there.Also include significant build/test/docs dependencies (Sphinx themes, pytest plugins, linters) that the project interacts with.
For each upstream repo, search for the maintainer's participation:
gh api "repos/{owner}/{repo}/issues?creator={username}&state=all&per_page=100" \
--jq '.[] | "#\(.number) \(.title) [\(.state)] \(.pull_request // empty | "PR") \(.html_url)"'
For repos with many results, also check PRs specifically:
gh search prs --author {username} --repo {owner}/{repo} --limit 50
For a maintainer active across many projects, sweep globally first and filter by repo afterwards: one search over everything they authored beats guessing the repo list, and surfaces upstreams nobody remembered.
gh search prs --author {username} --limit 1000 --json repository,number,title,state,url -- -user:{username}
gh search issues --author {username} --limit 1000 --json repository,number,title,state,url -- -user:{username}
Three traps in that sweep:
-user:{username}) must come after the -- separator, and every flag before it: anything after -- is read as a search term.--limit below the true total drops the oldest items silently. Treat a result count equal to the limit as truncated.When the maintainer runs several projects with upstream pages, dedupe against the sibling pages and give each item one canonical home. Pick it in this order:
CROSS_REFERENCED_EVENT and REFERENCED_EVENT timeline items through GraphQL to find those references. With no reference, judge by date and topic.Move an item found on the wrong sibling page to its home, and delete it from the old page in the same pass. Distribution packaging of the project itself belongs to its packaging docs, not this page.
For PRs: gh pr view <url> --json state,mergedAt,title
For issues: gh issue view <url> --json state,stateReason,title
To resolve many items at once, batch them into a single GraphQL call with aliased issueOrPullRequest nodes:
gh api graphql -F [email protected]
query {
a1: repository(owner: "{owner}", name: "{repo}") { issueOrPullRequest(number: 123) { ...S } }
a2: repository(owner: "{owner}", name: "{repo}") { issueOrPullRequest(number: 456) { ...S } }
}
fragment S on IssueOrPullRequest {
... on Issue { state stateReason title }
... on PullRequest { state merged title }
}
stateReason separates a completed issue from one closed as not planned, which decides its section.
Search the git log for upstream references not yet found:
git log --all --oneline --grep="github.com/" | head -100
Search the codebase for inline issue references:
git grep -nE 'github\.com/.*/(issues|pull)/' -- '*.py'
Also check docs/ and any changelog for upstream references.
| Item type | Status | Section |
|---|---|---|
| PR | merged | Code contributed upstream |
| PR | closed, not merged | Declined by upstream |
| PR | open | Open upstream |
| Issue | open or closed, this project still provides a workaround | Addressed by this project |
| Issue | closed as completed, no release ships the fix yet | Open upstream |
| Issue | closed as completed | Upstreamed from this project |
| Issue | closed as not planned | Declined by upstream |
| Issue | open, no local workaround | Open upstream |
The first matching row wins. List every issue the maintainer reported, even one closed with no local workaround ever needed. Skip a closed PR that its author withdrew, or that a later merged PR replaced: nobody declined it.
An issue kept in "Open upstream" after it closed names its fix: "closed by project#N, which no release carries yet". The fix is released once the newest release tag contains its merge commit: gh api repos/{owner}/{repo}/compare/{tag}...{sha} --jq .status then answers behind or identical.
To determine whether the project has a workaround for an issue, search the codebase for references to that issue URL or number.
Write the document following the five-section structure.
Give a project its own heading in one section only when docs/conf.py loads sphinx.ext.autosectionlabel: a repeated heading raises a duplicate-label warning. Elsewhere, write project#N in the item's link text.
Wrap an item whose title quotes a misspelling in <!-- typos:off --> and <!-- typos:on --> lines, or the fix-typos job rewrites the title.
audit)For every GitHub URL in the document, check its current state via gh:
gh pr view <url> --json state,mergedAtgh issue view <url> --json state,stateReasonFlag items that need to move:
| Current section | New state | Action |
|---|---|---|
| Open upstream | PR merged | Move to "Code contributed upstream" |
| Open upstream | Issue closed as completed | Move to "Addressed" if a workaround exists, else to "Upstreamed" once released |
| Open upstream | Closed as not planned | Move to "Declined by upstream" |
| Addressed by this project | Fixed upstream | Move to "Upstreamed from this project" |
sync-git)Search for upstream references not yet tracked:
git log --all --oneline --grep="github.com/" | head -100
git log --all --oneline --grep="upstream" | head -50
git log --all --oneline --grep="workaround" | head -50
git log --all --oneline --grep="backport" | head -50
For each new reference, determine which section it belongs to and report it.
For audit, produce a summary:
| Action | Count |
|---|---|
| Items to move | N |
| New items to add | N |
| Stale items to remove | N |
Then list each change with: URL, current section, recommended section, reason.
Do not edit the file until the user confirms (except with refresh).
docs/benchmark.mdThe upstream page and the benchmark page both track upstream issues and PRs. When items change status in docs/upstream.md (a gap gets fixed, a workaround gets upstreamed, a PR gets merged), check whether docs/benchmark.md has a corresponding entry in its "Gaps and opportunities" or feature tables that needs updating. Suggest running /benchmark-update audit afterward if upstream changes affect the competitive comparison.
What SKILL.md sets; muted values are Claude Code's defaults
Three short reads, in order
npx claudepluginhub kdeldycke/repomatic --plugin repomatic18 skills in this plugin
/av-false-positiveScan a release on VirusTotal. Write submission instructions for each AV vendor that flags a false positive./awesome-triageTriage new issues and PRs on awesome-list repos. Apply the curation criteria drawn from past decisions./babysit-ciMonitor the CI tests, lint, autofix, docs and Nuitka binary-build workflows. Diagnose each failure, fix the code, commit, and loop until every stable job passes. Ignore unstable failures./benchmark-updateCreate or update the competitive benchmark page (docs/benchmark.md) that compares this project against its alternatives. Check maintenance status, feature accuracy, new candidates and badge health./brand-assetsCreate project logo and banner SVGs, then export them to light and dark PNG variants. Use when you design a logo or banner, or regenerate the PNGs from their SVG source files./file-bug-reportWrite a bug report for an upstream project, or a reply on an existing issue. Read its contribution guidelines, issue templates and community norms first, then produce a markdown file ready to paste.Other plugins' skills for the same job