Skip to content

Develop

Develop #36

Workflow file for this run

name: CI
on: [pull_request]
jobs:
compliance:
name: NPM Audit Report
runs-on: ubuntu-latest
steps:
# Checkout Code
- name: Checkout Code
uses: actions/checkout@v4
# Audit Package.json
- name: NPM Audit Action
uses: oke-py/npm-audit-action@main
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
lint:
needs: compliance
runs-on: ubuntu-latest
steps:
- uses: actions/[email protected]
- uses: actions/[email protected]
with:
node-version: '20.x'
- run: npm ci --ignore-scripts
- run: npm run lint
build:
needs: lint
runs-on: ubuntu-latest
steps:
- uses: actions/[email protected]
- uses: actions/[email protected]
with:
node-version: '20.x'
- uses: actions/cache@v3
env:
cache-name: cache-node-modules
with:
path: |
**/lib
key: ${{ runner.os }}-node-${{ hashFiles('**/package-lock.json') }}
restore-keys: |
${{ runner.os }}-node-
- run: npm ci --ignore-scripts
- run: npm run build
test:
needs: build
runs-on: ubuntu-latest
steps:
- uses: actions/[email protected]
- uses: actions/[email protected]
with:
node-version: '20.x'
- uses: actions/cache@v3
env:
cache-name: cache-node-modules
with:
path: |
**/lib
key: ${{ runner.os }}-node-${{ hashFiles('**/package-lock.json') }}
restore-keys: |
${{ runner.os }}-node-
- run: npm ci --ignore-scripts
- name: Test
run: npm run test