Merge pull request #81 from dxc-technology/feature/vulnerabilities #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: Publish Next Version | |
on: | |
push: | |
branches: [master] | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v2 | |
- name: Install Node.js 16.x | |
uses: actions/setup-node@v1 | |
with: | |
node-version: 16.x | |
registry-url: https://registry.npmjs.org/ | |
- name: Install dependencies | |
run: npm install | |
- name: Build library | |
run: npx nx build halstack-react-hal | |
- name: Copy README | |
run: npx nx run copy | |
- name: Publish NEXT version to npm | |
run: | | |
sed -i "s#\"version\": \"0.0.0\"#\"version\": \"0.0.0-${GITHUB_SHA:0:7}\"#" ./lib/dist/package.json | |
cd lib/dist | |
npm publish --tag next --access public | |
env: | |
NODE_AUTH_TOKEN: ${{ secrets.NODE_AUTH_TOKEN }} |