Skip to content

Commit

Permalink
fix: access token from a dif job
Browse files Browse the repository at this point in the history
  • Loading branch information
haifeng-li-at-salesforce committed Jun 6, 2024
1 parent 4041df4 commit 8cd999c
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,8 @@ jobs:
}')
token=$(echo $response | jq -r '.token')
echo "NPM_TOKEN=$token" >> $GITHUB_ENV
- name: Output variable
run: echo "::set-output name=npmtoken::$NPM_TOKEN"

release:
name: Release
Expand All @@ -64,8 +66,11 @@ jobs:
- name: Install dependencies
run: npm clean-install
- run: npm run build
- run: |
echo "local npm token: ${{needs.localNPMRegistry.outputs.npmtoken}}"
echo "NPM_TOKEN=${{needs.localNPMRegistry.outputs.npmtoken}}" >> $GITHUB_ENV
- name: Release
run: npx semantic-release
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
NPM_TOKEN: ${{env.NPM_TOKEN}}
NPM_TOKEN: ${{needs.localNPMRegistry.outputs.npmtoken}}

0 comments on commit 8cd999c

Please sign in to comment.