Merge pull request #16 from Netatwork-de/dependabot/npm_and_yarn/brac… #66
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
name: build | |
on: | |
push: | |
branches: [ main ] | |
tags: [ v* ] | |
pull_request: | |
branches: [ main ] | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v2 | |
- name: install | |
run: npm ci | |
- uses: actions/setup-node@v1 | |
with: | |
node-version: '20.x' | |
registry-url: https://registry.npmjs.org/ | |
scope: netatwork | |
- name: build | |
run: npm run build | |
- name: test | |
run: npm test | |
# Note that this does not takes care of the versioning. | |
# Changelog generation, version tagging needs to be done, prior to this. | |
- name: publish to npm | |
run: npm publish --access public --@netatwork:registry=https://registry.npmjs.org/ | |
if: startsWith(github.ref, 'refs/tags/v') | |
env: | |
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }} |