@@ -2,14 +2,16 @@ name: Release CLI
22
33on :
44 push :
5- tags :
6- - " cli-v*"
7- workflow_dispatch :
8- inputs :
9- dry_run :
10- description : " Dry run: build and validate, skip actual publish"
11- type : boolean
12- default : true
5+ # TODO: revert after testing — restore tag trigger and workflow_dispatch
6+ # push:
7+ # tags:
8+ # - "cli-v*"
9+ # workflow_dispatch:
10+ # inputs:
11+ # dry_run:
12+ # description: "Dry run: build and validate, skip actual publish"
13+ # type: boolean
14+ # default: true
1315
1416permissions :
1517 contents : write
2830 fetch-depth : 0
2931
3032 - name : Abort if tag is not on main
31- if : github.event_name == 'push'
33+ if : false # TODO: revert — disabled for testing
3234 run : |
3335 set -euo pipefail
3436 git fetch origin main
4345 id : version
4446 working-directory : cli
4547 run : |
46- if [ "${{ github.event_name }}" = "push" ]; then
47- VERSION="${GITHUB_REF_NAME#cli-v}"
48- else
49- VERSION=$(node -p "require('./package.json').version")
50- fi
48+ # TODO: revert — always read from package.json for testing
49+ VERSION=$(node -p "require('./package.json').version")
5150 if ! echo "$VERSION" | grep -qE '^[0-9]+\.[0-9]+\.[0-9]+(-[a-zA-Z0-9.]+)?$'; then
5251 echo "::error::Invalid version: ${VERSION}"
5352 exit 1
5655 echo "Version: $VERSION"
5756
5857 - name : Validate version matches package.json
59- if : github.event_name == 'push'
58+ if : false # TODO: revert — needs tag, disabled for testing
6059 working-directory : cli
6160 env :
6261 TAG_VERSION : ${{ steps.version.outputs.version }}
@@ -156,19 +155,19 @@ jobs:
156155 } >> /tmp/release-notes.md
157156
158157 - name : Publish to npm (dry run)
159- if : inputs.dry_run
160158 working-directory : cli
161159 run : npm publish --provenance --ignore-scripts --dry-run
162160
163- - name : Publish to npm
164- if : ${{ !inputs.dry_run }}
165- working-directory : cli
166- run : npm publish --provenance --ignore-scripts
161+ # TODO: revert — skip real publish and GH release for testing
162+ # - name: Publish to npm
163+ # if: ${{ !inputs.dry_run }}
164+ # working-directory: cli
165+ # run: npm publish --provenance --ignore-scripts
167166
168167 # --- GitHub Release ---
169168
170169 - name : Create GitHub Release
171- if : ${{ !inputs.dry_run }}
170+ if : false # TODO: revert — disabled for testing
172171 env :
173172 GH_TOKEN : ${{ github.token }}
174173 TAG : ${{ github.ref_name }}
0 commit comments