v1.16.0 #72
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# This workflow will run tests using node and then publish a package to GitHub Packages when a release is created | |
# For more information see: https://help.github.com/actions/language-and-framework-guides/publishing-nodejs-packages | |
name: Node.js Package | |
on: | |
workflow_dispatch: | |
release: | |
types: [created] | |
permissions: | |
issues: read | |
pull-requests: read | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v2 | |
- uses: actions/setup-node@v1 | |
with: | |
node-version: 18 | |
- run: npm ci | |
- run: npm run build -w packages/notification | |
- run: npm test | |
test: | |
needs: build | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v2 | |
- uses: actions/setup-node@v1 | |
with: | |
node-version: 18 | |
- run: npm ci | |
- run: npm run build -w packages/notification | |
- run: npm pack | |
- run: npm install -g ./hyperjumptech-monika-*.tgz | |
- run: npm run prod_test | |
publish-npm: | |
needs: test | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v2 | |
- uses: actions/setup-node@v1 | |
with: | |
node-version: 18 | |
registry-url: https://registry.npmjs.org/ | |
- run: npm ci | |
- run: npm run build -w packages/notification | |
- run: npm publish --access public | |
env: | |
NODE_AUTH_TOKEN: ${{secrets.NPM_TOKEN}} | |
- name: Get Package Version | |
id: package-version | |
uses: martinbeentjes/npm-get-version-action@master | |
- name: Notify Teams | |
uses: joelwmale/webhook-action@fd99bb3b8272237103e349e9bb4d9b0ead9a217c | |
with: | |
url: ${{secrets.HYPERJUMP_TEAMS_SYMON_WEBHOOK}} | |
body: '{"title": "Monika NPM Release", "Text": "Version: ${{steps.package-version.outputs.current-version}}"}' |