Run NPM and snap builds on every push
To make sure these things still build. That means we need to make the actual deploy parts optional.
This commit is contained in:
parent
6784bb312f
commit
76aa3d1256
|
@ -1,6 +1,8 @@
|
||||||
name: Publish
|
name: Publish
|
||||||
|
|
||||||
on:
|
on:
|
||||||
|
push:
|
||||||
|
pull_request:
|
||||||
release:
|
release:
|
||||||
types: [published]
|
types: [published]
|
||||||
|
|
||||||
|
@ -17,11 +19,11 @@ jobs:
|
||||||
- run: npm publish --access public
|
- run: npm publish --access public
|
||||||
env:
|
env:
|
||||||
NODE_AUTH_TOKEN: ${{secrets.NPM_TOKEN}}
|
NODE_AUTH_TOKEN: ${{secrets.NPM_TOKEN}}
|
||||||
if: ${{ !github.event.release.prerelease }}
|
if: ${{ github.event_name == 'release' && !github.event.release.prerelease }}
|
||||||
- run: npm publish --access public --tag beta
|
- run: npm publish --access public --tag beta
|
||||||
env:
|
env:
|
||||||
NODE_AUTH_TOKEN: ${{secrets.NPM_TOKEN}}
|
NODE_AUTH_TOKEN: ${{secrets.NPM_TOKEN}}
|
||||||
if: ${{ github.event.release.prerelease }}
|
if: ${{ github.event_name == 'release' && github.event.release.prerelease }}
|
||||||
snap:
|
snap:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
container: snapcore/snapcraft
|
container: snapcore/snapcraft
|
||||||
|
@ -43,7 +45,8 @@ jobs:
|
||||||
echo ${SNAPCRAFT_LOGIN} | base64 --decode --ignore-garbage > .snapcraft/snapcraft.cfg
|
echo ${SNAPCRAFT_LOGIN} | base64 --decode --ignore-garbage > .snapcraft/snapcraft.cfg
|
||||||
env:
|
env:
|
||||||
SNAPCRAFT_LOGIN: ${{secrets.SNAPCRAFT_LOGIN}}
|
SNAPCRAFT_LOGIN: ${{secrets.SNAPCRAFT_LOGIN}}
|
||||||
|
if: ${{ github.event_name == 'release' }}
|
||||||
- run: snapcraft push --release=stable *.snap
|
- run: snapcraft push --release=stable *.snap
|
||||||
if: ${{ !github.event.release.prerelease }}
|
if: ${{ github.event_name == 'release' && !github.event.release.prerelease }}
|
||||||
- run: snapcraft push --release=beta *.snap
|
- run: snapcraft push --release=beta *.snap
|
||||||
if: ${{ github.event.release.prerelease }}
|
if: ${{ github.event_name == 'release' && github.event.release.prerelease }}
|
||||||
|
|
Loading…
Reference in New Issue