Skip to content

Merge pull request #23 from ant-media/update-version-test-final #26

Merge pull request #23 from ant-media/update-version-test-final

Merge pull request #23 from ant-media/update-version-test-final #26

name: Publish SNAPSHOT to npmjs
on:
push:
branches:
- main
jobs:
publish-npmjs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version: '16.x'
registry-url: 'https://registry.npmjs.org'
- uses: actions/setup-java@v3
with:
java-version: '11'
distribution: 'adopt'
- name: Update The Snapshot
id: get_version
run: echo "VERSION=$(echo ${GITHUB_REF##*/} | cut -d v -f 2)" >> $GITHUB_OUTPUT
- run: npm install --include=dev
- run: npm run compile
- run: npm test
#Fix this versioning for the snapshots
- run: npm version 2.12.0-SNAPSHOT"-`date +"%Y-%b-%d-%I-%M"`" --no-git-tag-version
- run: npm publish --tag SNAPSHOT
env:
NODE_AUTH_TOKEN: ${{secrets.NPM_TOKEN}}