Skip to content

Commit 7e72fd4

Browse files
committed
ci: fix release
closes #141
1 parent d0ef067 commit 7e72fd4

1 file changed

Lines changed: 11 additions & 6 deletions

File tree

.github/workflows/release.yml

Lines changed: 11 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -79,9 +79,6 @@ jobs:
7979
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
8080

8181
- uses: oxc-project/setup-node@4c31090ef1282f7c654edf77357894fc80ef5236 # v1.0.2
82-
with:
83-
registry-url: "https://npm.pkg.github.com/"
84-
scope: "@voidzero-dev"
8582

8683
- name: Bootstrap
8784
run: pnpm bootstrap-cli:ci
@@ -112,11 +109,19 @@ jobs:
112109
sed -i 's/"version": "0.0.0"/"version": "0.0.0-${{ github.sha }}"/' packages/global/package.json
113110
sed -i 's/"version": "0.0.0"/"version": "0.0.0-${{ github.sha }}"/' packages/cli/package.json
114111
112+
# Setup node correctly for publishing to github registry
113+
- uses: actions/setup-node@v5
114+
with:
115+
node-version-file: .node-version
116+
registry-url: "https://npm.pkg.github.com"
117+
scope: "@voidzero-dev"
118+
package-manager-cache: false
119+
120+
- run: npm install -g npm@latest # For trusted publishing support
121+
115122
- name: Publish
116123
run: |
117-
echo "//npm.pkg.github.com/:_authToken=${NPM_TOKEN}" >> ${NPM_CONFIG_USERCONFIG}
118-
echo "@voidzero-dev:registry=https://npm.pkg.github.com/" >> ${NPM_CONFIG_USERCONFIG}
119124
pnpm publish --filter=./packages/global --registry https://npm.pkg.github.com --no-git-checks
120125
pnpm publish --filter=./packages/cli --registry https://npm.pkg.github.com --no-git-checks
121126
env:
122-
NPM_TOKEN: ${{ secrets.GITHUB_TOKEN }}
127+
NODE_AUTH_TOKEN: ${{ secrets.GITHUB_TOKEN }}

0 commit comments

Comments
 (0)