Fix report script for unpublished packages #439
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: test-monorepo | |
on: | |
push: | |
branches: [main] | |
pull_request: | |
jobs: | |
# test npm publish dry-run | |
checkout_publish_skunkworks_dry_run: | |
runs-on: ubuntu-20.04 | |
steps: | |
- uses: actions/checkout@v3 | |
with: | |
repository: MetaMask/snaps-skunkworks | |
ref: 2befb570c72fddd577410b0193982332eed0fc41 | |
path: skunkworks | |
- uses: actions/checkout@v3 | |
with: | |
path: action-npm-publish | |
- name: Setup, Build, Publish | |
run: | | |
cd skunkworks | |
yarn install --immutable | |
yarn plugin import workspace-tools | |
PUBLISH_NPM_TAG="latest" ../action-npm-publish/scripts/main.sh | |
# test that publishing is skipped when attempting to republish the latest version | |
checkout_publish_skunkworks_skip: | |
runs-on: ubuntu-20.04 | |
steps: | |
- name: Get Latest Version from npm | |
id: latestrelease | |
run: echo "releasever=$(npm view MetaMask/snaps-skunkworks version --workspaces=false)" >> "$GITHUB_OUTPUT" | |
- uses: actions/checkout@v3 | |
with: | |
repository: MetaMask/snaps-skunkworks | |
ref: v${{ steps.latestrelease.outputs.releasever }} | |
path: skunkworks | |
- uses: actions/checkout@v3 | |
with: | |
path: action-npm-publish | |
- name: Setup, Build, Publish | |
run: | | |
cd skunkworks | |
yarn install --immutable | |
yarn plugin import workspace-tools | |
PUBLISH_NPM_TAG="latest" NPM_TOKEN="test" ../action-npm-publish/scripts/main.sh |