Repository navigation
Add MiniMax Code Badge plugin: a powered by MiniMax Code badge for GitHub pull requests - #79
Merged
hetaoBackend merged 1 commit intoNov 10, 2026
Conversation
…r GitHub PRs Adds plugins/hetaoBackend/minimax-code-badge, a Skill-first Agent Plugin that appends a "powered by MiniMax Code" badge to the end of GitHub pull request descriptions. The badge is one line of Markdown pointing at a Shields.io image, wrapped in HTML comment markers that GitHub does not render. The package ships scripts/badge.mjs, a dependency-free idempotent writer that adds, refreshes, checks, or removes the badge on a local body file or on an existing PR through the GitHub CLI, plus bundled SVG and PNG fallbacks and 17 local tests.
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 changes
Adds one new community Plugin:
plugins/hetaoBackend/minimax-code-badge.It appends a small "powered by MiniMax Code" badge to the end of a GitHub pull request description
created with MiniMax Code.
The badge is one line of Markdown pointing at a Shields.io image, wrapped in two HTML comment
markers that GitHub does not render. The Skill decides when a PR should carry it; a dependency-free
Node.js script writes it idempotently.
User value
A pull request produced with an agent is easy to mistake for hand-written work. This Plugin lets the
agent say which tool produced it, in the one place a reviewer already looks, without adding a bot
comment, an extra notification, or a platform API call.
Example prompts:
Expected result: the description keeps all of its original content and gains exactly one badge block
at the very end, separated by one blank line. The markers stay invisible on GitHub. Re-running the
writer reports
unchangedand performs no write, so a retried run cannot duplicate the badge.Usage
Status is printed on stderr:
added,replaced,unchanged,removed,absent, ordisabled.--checkexits 1 when the body is not up to date.MINIMAX_CODE_BADGE_DISABLE=1turns the scriptinto a no-op;
MINIMAX_CODE_BADGE_MARKDOWNchanges the wording.Files
Dependencies and supported platforms
scripts/badge.mjs. No npm dependencies, no build step.gh), already authenticated, only when writing to an existing PR. The localbody-file mode never calls
gh.Network and data behaviour
The Plugin makes no network requests and starts no server.
badge.mjsreaches the network onlythrough the user's own
ghCLI when the user asks it to update an existing PR: it reads the currentdescription with
gh pr view --json body,urland writes the new one withgh pr edit --body-file,using the user's existing GitHub credentials. No credentials are stored, logged, or transmitted, and
there is no telemetry.
The rendered badge image is loaded by the reader's browser from
https://img.shields.iowhenthe PR page is displayed, and links to
https://github.com/MiniMax-AI/minimax-code. GitHub servessuch images through its own image proxy, so a reader does not contact Shields.io directly.
The bundled
assets/minimax-code-badge.svgand.pngare offline copies of the same badge fordocuments that cannot load remote images.
Evidence
Validated on a real, public GitHub pull request owned by the author
(
hetaoBackend/agentforge#51):gh pr view --json body, count markers andimg.shields.ioGH_BINshimunchanged; shim recorded onlygh pr view, zerogh pr editcalls--checkok, exit 0curlthe badge URLcontent-type: image/svg+xml, 179x20, brand colour#e73562curl -LRepository checks on this branch:
node scripts/validate.mjs→OK plugin hetaoBackend/minimax-code-badge,Validated 30 hosted Plugins and all examples.node --test plugins/hetaoBackend/minimax-code-badge/skills/minimax-code-badge/scripts/badge.test.mjs→ 17 pass, 0 fail. All tests use local fake data; the
--prtests run against a fakeghexecutable that reads and writes a JSON file, so the suite never contacts GitHub.
npm run check→ 1138 pass, 1 fail. The single failure isplugins/antianqi/mcode-island/scripts/test-substep-progress.mjs, a pre-existing PowerShell-onlytest in another contributor's Plugin that needs
pwshon PATH. It is unrelated to this Plugin andfails on a clean checkout of
mainon a machine without PowerShell.Design notes
The mechanism follows the public DeepSeek Harness badge Skill (
@deepseek-ai/dsh-skill-badge): oneSkill instruction, one fixed Markdown block, and bundled images, with no model tools, no platform
API, and no hooks. The idempotent writer is the part this Plugin adds on top of that pattern.
Known limitations
every
gh pr create. Runningbadge.mjs --pr <n>afterwards is the deterministic path.img.shields.ioat render time for the primary image. The bundled SVG andPNG cover documents that cannot load remote images, but they are not used automatically on GitHub.
but the Skill requires the user to ask for that specific MR.
normal approval rules before calling
gh pr edit.Submission checklist
plugins/<github-owner>/<plugin-name>.plugin.jsonname matches the Plugin directory.README.mdincludes a real example prompt and expected result.LICENSEandplugin.jsondeclare an open-source license (Apache-2.0).TODOhas been replaced.npm run checkpasses for this Plugin.Open in [code]smith · Need help on this PR? Tag
@codesmith-botwith what you need.