diff options
author | Pierre Ossman <ossman@cendio.se> | 2021-11-09 15:59:44 +0100 |
---|---|---|
committer | Pierre Ossman <ossman@cendio.se> | 2021-11-09 15:59:44 +0100 |
commit | a012f98b61453ac23da3323c7b53f588c1f116f5 (patch) | |
tree | 03611d8c2c4b0cf4cca59ccb880c357bc95ce261 | |
parent | 2c48df45605f7429ea30eeffd0acb0e23e10f2dc (diff) | |
parent | 98243fc68f8b786fdc7790fc9c0e9e24becee970 (diff) | |
download | novnc-a012f98b61453ac23da3323c7b53f588c1f116f5.tar.gz |
Merge branch 'snap' of https://github.com/CendioOssman/noVNC
-rw-r--r-- | .github/workflows/deploy.yml | 20 | ||||
-rw-r--r-- | snap/snapcraft.yaml | 6 |
2 files changed, 26 insertions, 0 deletions
diff --git a/.github/workflows/deploy.yml b/.github/workflows/deploy.yml index 09bea6a..48cb031 100644 --- a/.github/workflows/deploy.yml +++ b/.github/workflows/deploy.yml @@ -11,6 +11,11 @@ jobs: runs-on: ubuntu-latest steps: - uses: actions/checkout@v2 + - run: | + GITREV=$(git rev-parse --short HEAD) + echo $GITREV + sed -i "s/^\(.*\"version\".*\)\"\([^\"]\+\)\"\(.*\)\$/\1\"\2-g$GITREV\"\3/" package.json + if: ${{ github.event_name == 'push' && github.event.ref == 'ref/heads/master' }} - uses: actions/setup-node@v1 with: # Needs to be explicitly specified for auth to work @@ -28,11 +33,20 @@ jobs: env: NODE_AUTH_TOKEN: ${{secrets.NPM_TOKEN}} if: ${{ github.event_name == 'release' && github.event.release.prerelease }} + - run: npm publish --access public --tag dev + env: + NODE_AUTH_TOKEN: ${{secrets.NPM_TOKEN}} + if: ${{ github.event_name == 'push' && github.event.ref == 'ref/heads/master' }} snap: runs-on: ubuntu-latest steps: - uses: actions/checkout@v2 - run: | + GITREV=$(git rev-parse --short HEAD) + echo $GITREV + sed -i "s/^\(.*\"version\".*\)\"\([^\"]\+\)\"\(.*\)\$/\1\"\2-g$GITREV\"\3/" package.json + if: ${{ github.event_name == 'push' && github.event.ref == 'ref/heads/master' }} + - run: | VERSION=$(grep '"version"' package.json | cut -d '"' -f 4) echo $VERSION sed -i "s/@VERSION@/$VERSION/g" snap/snapcraft.yaml @@ -54,3 +68,9 @@ jobs: snap: ${{ steps.snapcraft.outputs.snap }} release: beta if: ${{ github.event_name == 'release' && github.event.release.prerelease }} + - uses: snapcore/action-publish@v1 + with: + store_login: ${{ secrets.SNAPCRAFT_LOGIN }} + snap: ${{ steps.snapcraft.outputs.snap }} + release: edge + if: ${{ github.event_name == 'push' && github.event.ref == 'ref/heads/master' }} diff --git a/snap/snapcraft.yaml b/snap/snapcraft.yaml index ffba501..3549c78 100644 --- a/snap/snapcraft.yaml +++ b/snap/snapcraft.yaml @@ -23,6 +23,9 @@ parts: - core/**/*.js - vendor/**/*.js - novnc_proxy + + novnc-deps: + plugin: nil stage-packages: - bash @@ -31,6 +34,9 @@ parts: plugin: dump stage: - svc_wrapper.sh + + svc-script-deps: + plugin: nil stage-packages: - bash - jq |