mirror of
https://github.com/jakejarvis/jarv.is.git
synced 2025-04-27 04:38:28 -04:00
55 lines
1.4 KiB
YAML
55 lines
1.4 KiB
YAML
name: CI
|
|
|
|
on:
|
|
push:
|
|
branches:
|
|
- main
|
|
pull_request:
|
|
|
|
jobs:
|
|
lint:
|
|
runs-on: ubuntu-latest
|
|
if: "!contains(github.event.head_commit.message, '[skip ci]')"
|
|
steps:
|
|
- uses: actions/checkout@v2
|
|
with:
|
|
fetch-depth: 1
|
|
- uses: actions/setup-node@v2
|
|
with:
|
|
node-version: 14.x
|
|
cache: yarn
|
|
- run: yarn install --frozen-lockfile
|
|
- run: yarn lint
|
|
|
|
snapshot:
|
|
runs-on: ubuntu-latest
|
|
if: "github.actor == 'jakejarvis' && !contains(github.event.head_commit.message, '[skip ci]')"
|
|
steps:
|
|
- uses: actions/checkout@v2
|
|
with:
|
|
fetch-depth: 1
|
|
- uses: actions/setup-node@v2
|
|
with:
|
|
node-version: 14.x
|
|
cache: yarn
|
|
- run: yarn install --frozen-lockfile
|
|
- run: NODE_ENV=production yarn build
|
|
- run: yarn percy
|
|
env:
|
|
PERCY_TOKEN: ${{ secrets.PERCY_TOKEN }}
|
|
|
|
audit:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- uses: actions/checkout@v2
|
|
with:
|
|
fetch-depth: 0
|
|
- name: GitGuardian scan
|
|
uses: GitGuardian/gg-shield-action@master
|
|
env:
|
|
GITHUB_PUSH_BEFORE_SHA: ${{ github.event.before }}
|
|
GITHUB_PUSH_BASE_SHA: ${{ github.event.base }}
|
|
GITHUB_PULL_BASE_SHA: ${ github.event.pull_request.base.sha }}
|
|
GITHUB_DEFAULT_BRANCH: ${ github.event.repository.default_branch }}
|
|
GITGUARDIAN_API_KEY: ${ secrets.GITGUARDIAN_API_KEY }}
|