From 4d9249959c481a05f2c3d6675b97e179b2632d27 Mon Sep 17 00:00:00 2001 From: Mikel Larreategi Date: Thu, 28 Oct 2021 16:18:16 +0200 Subject: [PATCH] reowkr --- .github/workflows/release.yml | 24 +++++++++++------------- 1 file changed, 11 insertions(+), 13 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 066e8af..3e9c166 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -1,6 +1,13 @@ +on: + pull_request: + branches: + - main + types: [closed] + jobs: release: runs-on: ubuntu-latest + if: github.event.pull_request.merged == true steps: - uses: actions/checkout@v2 with: @@ -11,17 +18,8 @@ jobs: git config user.email "${GITHUB_ACTOR}@users.noreply.github.com" - run: npm install - run: npm run release - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - deploy: - script: - - echo "//registry.npmjs.org/:_authToken=$NPM_TOKEN" > .npmrc - - npm run release + - run: echo "//registry.npmjs.org/:_authToken=$NPM_TOKEN" > .npmrc + - run: npm run release -on: - pull_request: - branches: - - main - steps: - - release - - deploy + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}