diff --git a/.github/workflows/npm.yml b/.github/workflows/npm.yml index fef534e..cece28a 100644 --- a/.github/workflows/npm.yml +++ b/.github/workflows/npm.yml @@ -36,6 +36,13 @@ jobs: registry-url: 'https://registry.npmjs.org' scope: '@screeps' - name: 📦️ Publish package (npmjs) + if: github.ref_name == 'master' run: npm publish env: NODE_AUTH_TOKEN: ${{ secrets.NPMJS_TOKEN }} + - name: 📦️ Publish package (npmjs) + if: github.ref_name != 'master' + run: npm publish --tag github.ref_name + env: + NODE_AUTH_TOKEN: ${{ secrets.NPMJS_TOKEN }} + \ No newline at end of file