feat: release qwen-code CLI packages as a standalone bundled js, with necessary vendors

This commit is contained in:
tanzhenxin
2025-10-23 15:57:16 +08:00
parent 5cf609c367
commit ab28db1da8
23 changed files with 712 additions and 695 deletions

View File

@@ -163,9 +163,9 @@ jobs:
echo "Dry run enabled. Skipping push."
fi
- name: 'Build and Prepare Packages'
- name: 'Build Bundle and Prepare Package'
run: |-
npm run build:packages
npm run bundle
npm run prepare:package
- name: 'Configure npm for publishing'
@@ -175,20 +175,10 @@ jobs:
registry-url: 'https://registry.npmjs.org'
scope: '@qwen-code'
- name: 'Publish @qwen-code/qwen-code-core'
run: |-
npm publish --workspace=@qwen-code/qwen-code-core --access public --tag=${{ steps.version.outputs.NPM_TAG }} ${{ steps.vars.outputs.is_dry_run == 'true' && '--dry-run' || '' }}
env:
NODE_AUTH_TOKEN: '${{ secrets.NPM_TOKEN }}'
- name: 'Install latest core package'
if: |-
${{ steps.vars.outputs.is_dry_run == 'false' }}
run: 'npm install @qwen-code/qwen-code-core@${{ steps.version.outputs.RELEASE_VERSION }} --workspace=@qwen-code/qwen-code --save-exact'
- name: 'Publish @qwen-code/qwen-code'
working-directory: dist
run: |-
npm publish --workspace=@qwen-code/qwen-code --access public --tag=${{ steps.version.outputs.NPM_TAG }} ${{ steps.vars.outputs.is_dry_run == 'true' && '--dry-run' || '' }}
npm publish --access public --tag=${{ steps.version.outputs.NPM_TAG }} ${{ steps.vars.outputs.is_dry_run == 'true' && '--dry-run' || '' }}
env:
NODE_AUTH_TOKEN: '${{ secrets.NPM_TOKEN }}'
@@ -202,7 +192,7 @@ jobs:
PREVIOUS_TAG: '${{ steps.version.outputs.PREVIOUS_TAG }}'
run: |-
gh release create "${RELEASE_TAG}" \
bundle/gemini.js \
dist/cli.js \
--target "$RELEASE_BRANCH" \
--title "Release ${RELEASE_TAG}" \
--notes-start-tag "$PREVIOUS_TAG" \