Skip to content

Merge Develop to Main #125

Merge Develop to Main

Merge Develop to Main #125

Workflow file for this run

name: Test
on:
pull_request:
branches: [ develop, main ]
jobs:
lint:
runs-on: ubuntu-latest
if: ${{ github.event.pull_request.head.repo.owner.login == github.repository_owner }}
name: Lint
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Read `.nvmrc`
run: echo "::set-output name=nvmrc::$(cat .nvmrc)"
id: nvm
- name: Use Node.js (.nvmrc)
uses: actions/setup-node@v1
with:
node-version: "${{ steps.nvm.outputs.nvmrc }}"
- name: Read `yarn cache dir`
id: yarn-cache-dir-path
run: echo "::set-output name=dir::$(yarn config get cacheFolder)"
- name: Load yarn cache
uses: actions/cache@v2
id: yarn-cache
with:
path: ${{ steps.yarn-cache-dir-path.outputs.dir }}
key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
restore-keys: |
${{ runner.os }}-yarn-
- name: Install dependencies
run: yarn install --immutable
- name: Lint
uses: wearerequired/lint-action@v1.9.0
with:
github_token: ${{ secrets.github_token }}
eslint: true
eslint_extensions: js,cjs,mjs
eslint_args: "--max-warnings 0"
build:
runs-on: ubuntu-latest
name: Build Test
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Read `.nvmrc`
run: echo "::set-output name=nvmrc::$(cat .nvmrc)"
id: nvm
- name: Use Node.js (.nvmrc)
uses: actions/setup-node@v1
with:
node-version: "${{ steps.nvm.outputs.nvmrc }}"
- name: Read `yarn cache dir`
id: yarn-cache-dir-path
run: echo "::set-output name=dir::$(yarn config get cacheFolder)"
- name: Load yarn cache
uses: actions/cache@v2
id: yarn-cache
with:
path: ${{ steps.yarn-cache-dir-path.outputs.dir }}
key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
restore-keys: |
${{ runner.os }}-yarn-
- name: Install dependencies
run: yarn install --immutable
- name: Build
run: yarn build