Skip to content

Never stop coding. Free MIT AI gateway: one endpoint, 375 providers (150+ free), 1,400+ models Kimi, Claude, GPT, Gemini, GLM, DeepSeek, MiniMax. Works with Claude Code, Codex, Cursor, OpenCode, Cline & Copilot. Quota-aware auto-fallback, RTK+Caveman compression saves 15-95% tokens, MCP/A2A, Desktop/PWA. Built by 900+ contributors

ci: add workflow_dispatch to npm-publish, fix version sync for manual triggers

diegosouzapwd0fb4576a8e3
diff --git a/.github/workflows/npm-publish.yml b/.github/workflows/npm-publish.yml
index 14b08da04a..aa0739d10c 100644
--- a/.github/workflows/npm-publish.yml
+++ b/.github/workflows/npm-publish.yml
@@ -3,6 +3,12 @@ name: Publish to npm
on:
release:
types: [published]
+ workflow_dispatch:
+ inputs:
+ version:
+ description: "Version tag to publish (e.g. 2.6.0)"
+ required: true
+ type: string
permissions:
contents: read
@@ -25,11 +31,14 @@ jobs:
- name: Install dependencies (skip scripts to avoid heavy build)
run: npm install --ignore-scripts --no-audit --no-fund
- - name: Sync version from release tag
+ - name: Sync version from release tag or input
run: |
- VERSION="${GITHUB_REF_NAME}"
- # Remove 'v' prefix if present (v2.1.0 -> 2.1.0)
- VERSION="${VERSION#v}"
+ if [ "${{ github.event_name }}" = "workflow_dispatch" ]; then
+ VERSION="${{ inputs.version }}"
+ else
+ VERSION="${GITHUB_REF_NAME}"
+ VERSION="${VERSION#v}"
+ fi
npm version "$VERSION" --no-git-tag-version --allow-same-version
echo "Publishing version: $VERSION"