Skip to content
This repository has been archived by the owner on Jun 24, 2024. It is now read-only.

Commit

Permalink
add npm variable
Browse files Browse the repository at this point in the history
  • Loading branch information
Vahor committed Aug 27, 2023
1 parent a68fade commit 6209db7
Showing 1 changed file with 24 additions and 3 deletions.
27 changes: 24 additions & 3 deletions .github/workflows/snapshot-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,10 @@ jobs:
uses: peter-evans/create-or-update-comment@v3
with:
comment-id: ${{ github.event.comment.id }}
reactions: eyes
body: |
@${{ github.actor }} your snapshot release is being processed.
:eyes: Please wait while we run the release process.
- name: Enforce permission requirement
id: check-permissions
Expand Down Expand Up @@ -73,6 +76,14 @@ jobs:
- name: Install deps
run: pnpm install --child-concurrency 3 --frozen-lockfile --prefer-offline

- name: Create an .npmrc
env:
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
run: |
cat << EOF > "$HOME/.npmrc"
//registry.npmjs.org/:_authToken=$NPM_TOKEN
EOF
- name: Run Changeset
id: changeset
run: |
Expand All @@ -81,7 +92,6 @@ jobs:
pnpm exec changeset publish --tag
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}

- name: Format changeset comment
id: format-comment
Expand All @@ -101,4 +111,15 @@ jobs:
```
${{ steps.format-comment.outputs.changesetComment }}
```
```
- name: Send failure comment
uses: peter-evans/create-or-update-comment@v3
if: failure()
with:
comment-id: ${{ github.event.comment.id }}
reactions: x
body: |
@${{ github.actor }} your snapshot release failed to publish.
Please check the logs for more information.

0 comments on commit 6209db7

Please sign in to comment.