Merge pull request #1391 from sasjs/lintfix #585
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: SASjs CLI Deploy | |
on: | |
push: | |
branches: | |
- main | |
jobs: | |
release: | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
node-version: [lts/hydrogen] | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v2 | |
- name: Use Node.js ${{ matrix.node-version }} | |
uses: actions/setup-node@v2 | |
with: | |
node-version: ${{ matrix.node-version }} | |
cache: npm | |
- name: Install dependencies | |
run: | | |
npm config set registry https://registry.npmjs.org | |
npm ci | |
- name: Build Project | |
run: npm run build | |
- name: Check npm audit | |
run: npm audit --omit=dev --audit-level=low | |
- name: Set NPM Registry back to https | |
run: npm config set registry https://registry.npmjs.org | |
- name: Semantic Release | |
uses: cycjimmy/semantic-release-action@v3 | |
with: | |
node-version: ${{ matrix.node-version }} | |
cache: npm | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
NPM_TOKEN: ${{ secrets.NPM_TOKEN }} |