From 22d1e6db91a9fe30405a76ef41e3db2d19953d8d Mon Sep 17 00:00:00 2001 From: Kohei Watanabe Date: Tue, 6 Jul 2021 13:50:51 +0900 Subject: [PATCH] use actions/setup-node --- .github/workflows/publish.yml | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml index d6f769f..58dee5f 100644 --- a/.github/workflows/publish.yml +++ b/.github/workflows/publish.yml @@ -7,13 +7,11 @@ jobs: runs-on: ubuntu-latest steps: - uses: actions/checkout@v2 - - id: yarn_cache - run: echo "::set-output name=dir::$(yarn cache dir)" - - uses: actions/cache@v2 + - uses: actions/setup-node@v2 with: - path: ${{ steps.yarn_cache.outputs.dir }} - key: yarn-${{ hashFiles('**/yarn.lock') }} - restore-keys: yarn- + node-version: 14 + cache: yarn + registry-url: https://registry.npmjs.org/ - run: yarn - name: Git configuration. run: | @@ -23,5 +21,6 @@ jobs: run: | npm version patch git push --atomic --tags origin HEAD - echo "//registry.npmjs.org/:_authToken=${{ secrets.NPM_TOKEN }}" >> ~/.npmrc npm publish + env: + NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}