diff --git a/.github/workflows/deploy.yml b/.github/workflows/deploy.yml index bf1ca55..47edd48 100644 --- a/.github/workflows/deploy.yml +++ b/.github/workflows/deploy.yml @@ -59,7 +59,7 @@ jobs: with: node-version: "12" # Needed for publishing to npm - registry-url: "https://registry.npmjs.org" + registry-url: https://npm.pkg.github.com # Run `npm ci && npm run build` to re-create your local environment (make sure to commit your - package-lock.json!). - name: Build @@ -91,6 +91,7 @@ jobs: - name: Publish if: github.ref == 'refs/heads/production' run: | + npm set //registry.npmjs.org/:_authToken ${{ secrets.NPM_AUTH_TOKEN }} npm publish VERSION="$(node -p "require('./package.json').version")" echo package_version=${VERSION} >> $GITHUB_ENV @@ -101,6 +102,7 @@ jobs: - name: Publish to beta if: github.ref == 'refs/heads/testing' run: | + npm set //registry.npmjs.org/:_authToken ${{ secrets.NPM_AUTH_TOKEN }} npm publish --tag beta VERSION="$(node -p "require('./package.json').version")@beta" echo package_version=${VERSION} >> $GITHUB_ENV