- TypeScript 90.1%
- JavaScript 9.9%
| Filename | Latest commit message | Latest commit date |
|---|---|---|
|
|
||
| .forgejo/workflows | ||
| forgejo-issues | ||
| scripts | ||
| .gitignore | ||
| CLAUDE.md | ||
| LICENSE | ||
| README.md | ||
forgejo-issues-claude-plugin
Claude Code plugin: a pane listing the open Forgejo issues of the current repo (read from
git remote origin), with issue details and an Implement button that runs the
implement-issue skill in the active session.
Usage
A band above the prompt shows the repo and the number of open issues:
forgejo · owner/repo [7 open issues ›] [↻]. Its button (hotkey i while the band has the
focus) opens or closes the pane, ↻ reloads. Problems such as a missing token or a folder
without a Forgejo remote show as text in the band. The band steps back while a survey or a turn
runs and collapses with its [-].
In the Claude desktop app a new chat shows the band only once its session runs: after the first
message, when the answer is done. Before that no plugin is loaded for the chat, so nothing can
draw the band, and autoOpen takes effect at that point too.
The pane lists the issues sorted by last update, 50 at a time (Load more for the rest). Its
head shows the repo, the count, when it was loaded, a link to the issues in the browser and
Reload (hotkey r). Each issue starts with its reference in bold: a title prefix such as
FIP-12: when the repo's Actions variable ISSUE_PREFIX is FIP and the number matches,
otherwise #12. Where the variable cannot be read, a prefix counts when at least two loaded titles
start with it and their own numbers. Below the title up to three labels show
as chips in their Forgejo colors, then the author and the age. /forgejo-issues opens the pane
too; the typeahead lists it as /forgejo-issues:forgejo-issues. Set the option autoOpen to open it at session start; where the window is too narrow the
pane stays closed until opened from the band.
Pressing an issue opens its detail: ‹ Back (hotkey b) and a link to the issue in the browser,
the title, labels, author and age, then Implement, which has the focus. The body below is drawn
as Markdown; images and raw HTML show as text, link targets are shown, and a long body is cut
with Show more. Implement starts implement-issue at once for your own issues; for an issue
of another author it asks first, and Cancel starts nothing. While a turn runs the prompt
starts after it.
In the desktop app Implement also names the chat after the issue, as FIP-12: Title (#12 Title
without a prefix), cut to 60 characters. The app replaces a title it generated and asks before it
replaces one you set yourself. Without the desktop app, or if renaming fails, implement-issue
starts anyway.
Install
The plugin is published through the marketplace msc in the repo
keineantwort.de/claude-plugins.
Both repos are readable without authentication; no local checkout is needed.
claude plugin marketplace add https://forgejo.home.msc.wtf/keineantwort.de/claude-plugins.git
claude plugin install forgejo-issues@msc
Token
Run /plugin configure forgejo-issues@msc in Claude Code (or claude plugin configure forgejo-issues@msc)
and set the Forgejo URL and an API token. Create the token in Forgejo under
Settings → Applications → Access tokens with the scopes read:issue and read:user. It is
stored as a sensitive option. read:user lets the plugin read your login, so Implement knows
your own issues; without it every Implement asks first. Reading the repo's ISSUE_PREFIX
needs read:repository and admin rights on the repo; without them the prefix comes from the
titles.
The Forgejo URL must use https: (http: only for localhost). The pane only queries Forgejo
when the host of git remote origin matches the host of that URL.
Refresh
The open issues reload at session start, when a client attaches, when the working folder changes,
every refreshMinutes (default 5) and on Reload. Only one request runs at a time.
Update
Releases are pinned to a tag and commit in the marketplace. Claude Code only sees a new
release when the version in plugin.json changes.
Auto-update is the intended setup. Turn it on in /plugin → Marketplaces → msc, or
declare the marketplace in ~/.claude/settings.json:
{
"extraKnownMarketplaces": {
"msc": {
"source": { "source": "git", "url": "https://forgejo.home.msc.wtf/keineantwort.de/claude-plugins.git" },
"autoUpdate": true
}
}
}
Update by hand:
claude plugin marketplace update msc
claude plugin update forgejo-issues@msc
Migration from msc-local
The plugin ID changes from forgejo-issues@msc-local to forgejo-issues@msc, so the token
has to be set again.
claude plugin uninstall forgejo-issues@msc-local
claude plugin marketplace remove msc-local
claude plugin marketplace add https://forgejo.home.msc.wtf/keineantwort.de/claude-plugins.git
claude plugin install forgejo-issues@msc
Then set the token as described above. Remove a leftover msc-local entry from
extraKnownMarketplaces in ~/.claude/settings.json.
Release
- Raise
versioninforgejo-issues/.claude-plugin/plugin.jsonin the pull request. CI fails if a pull request changesforgejo-issues/without raising it. - Merge to
main. The workflow.forgejo/workflows/ci.ymlvalidates the plugin, pushes the tagv<version>and pins the marketplace entry to that tag and commit.
A failed marketplace update is picked up by the next push to main or a manual run
(Actions → Validate and Release → Run workflow).
Development
claude --plugin-dir ./forgejo-issues # load the working copy for one session
claude plugin validate ./forgejo-issues
claude plugin test ./forgejo-issues # tests of the hooks module
node --test 'scripts/*.test.mjs'
Dev plugin
To try a branch in the Claude desktop app next to the released plugin, build a renamed copy,
forgejo-issues-dev, with its own command /forgejo-issues-dev, pane, state and token:
node scripts/dev-plugin.mjs # writes .dev/forgejo-issues-dev and the marketplace msc-dev
Once, from the repo root:
claude plugin marketplace add ./.dev
claude plugin install forgejo-issues-dev@msc-dev
claude plugin configure forgejo-issues-dev@msc-dev
After each change (or branch switch) run the script again and /reload-plugins in the session.
The marketplace lists the copy by relative path, so Claude Code reads it from .dev/ directly.
The script replaces only the exact literal 'forgejo-issues': the state references must be literals
and a module cannot read its own plugin name at run time.
Layout
forgejo-issues/: the plugin (manifest, hooks module, types, tests undertests/)scripts/ci.mjs: version check and marketplace entry for the CIscripts/dev-plugin.mjs: renamed dev copyforgejo-issues-devand local marketplacemsc-dev.forgejo/workflows/ci.yml: validation on every push and pull request, release onmain
Security
- Only the operator has write access (2FA).
mainis protected in both repos (push only by the operator; in the marketplace repo also by the deploy key). - Tags
v*are not protected: Forgejo does not attribute deploy-key pushes to a user, so a tag protection would block the CI. Installs do not depend on the tag, the marketplace pins the commit. - The CI writes with the shared deploy key
SSH_DEPLOY_KEY(same key as the HomeLab repos), registered with write access in this repo (release tag) and in the marketplace repo. There is no personal token. The secret is only used in the release job onmain, never in pull requests. - The Forgejo instance is reachable from the internet. The repos are public but not advertised; the marketplace pins every entry to a commit.