name: release on: push: branches: - preview - master - v*.x jobs: prepare: runs-on: ubuntu-latest if: "! contains(github.event.head_commit.message, '[ci skip]')" steps: - run: echo "${{ github.event.head_commit.message }}" release: runs-on: ubuntu-latest needs: prepare steps: - uses: actions/checkout@v2 - uses: actions/cache@v1 with: path: ~/.npm key: ${{ runner.os }}-node - run: npm run release env: NPM_TOKEN: ${{secrets.NPM_TOKEN}} GH_TOKEN: ${{secrets.GH_TOKEN}}