chore #488
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
name: Run linter and tests | |
on: | |
push: | |
branches-ignore: | |
- master | |
- develop | |
paths: | |
- '**.js' | |
- '**.json' | |
- '**.ts' | |
jobs: | |
start: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v2 | |
- name: Setup node.js | |
uses: actions/setup-node@v1 | |
with: | |
node-version: 12.x | |
- name: Determine npm cache directory | |
id: npm-cache | |
run: echo "::set-output name=dir::$(npm config get cache)" | |
- name: Restore npm cache | |
uses: actions/cache@v2 | |
with: | |
path: ${{ steps.npm-cache.outputs.dir }} | |
key: ${{ runner.os }}-node-${{ hashFiles('**/package-lock.json') }} | |
restore-keys: | | |
${{ runner.os }}-node- | |
- name: Install dependencies | |
run: npm ci | |
- name: Run linter | |
run: npm run lint | |
- name: Run unit tests | |
run: npm run test:unit |