11 runs-on: ubuntu-latest
13 - uses: actions/checkout@v2
14 - uses: actions/setup-node@v1
16 # Needs to be explicitly specified for auth to work
17 registry-url: 'https://registry.npmjs.org'
19 - run: npm publish --access public
21 NODE_AUTH_TOKEN: ${{secrets.NPM_TOKEN}}
22 if: ${{ github.event_name == 'release' && !github.event.release.prerelease }}
23 - run: npm publish --access public --tag beta
25 NODE_AUTH_TOKEN: ${{secrets.NPM_TOKEN}}
26 if: ${{ github.event_name == 'release' && github.event.release.prerelease }}
28 runs-on: ubuntu-latest
29 container: snapcore/snapcraft
31 - uses: actions/checkout@v2
32 - uses: actions/setup-node@v1
34 - run: ./utils/use_require.js --clean --as commonjs --with-app
36 cp utils/launch.sh build/launch.sh
37 cp snap/local/svc_wrapper.sh build/svc_wrapper.sh
39 VERSION=$(grep '"version"' package.json | cut -d '"' -f 4)
41 sed -i "s/@VERSION@/$VERSION/g" snap/snapcraft.yaml
45 echo ${SNAPCRAFT_LOGIN} | base64 --decode --ignore-garbage > .snapcraft/snapcraft.cfg
47 SNAPCRAFT_LOGIN: ${{secrets.SNAPCRAFT_LOGIN}}
48 if: ${{ github.event_name == 'release' }}
49 - run: snapcraft push --release=stable *.snap
50 if: ${{ github.event_name == 'release' && !github.event.release.prerelease }}
51 - run: snapcraft push --release=beta *.snap
52 if: ${{ github.event_name == 'release' && github.event.release.prerelease }}