Merge GitHub actions
This commit is contained in:
parent
9affe7b1f6
commit
f4545adc1c
2 changed files with 12 additions and 25 deletions
24
.github/workflows/check-format-and-lint.yaml
vendored
24
.github/workflows/check-format-and-lint.yaml
vendored
|
|
@ -1,24 +0,0 @@
|
||||||
name: Check formatting and lint
|
|
||||||
|
|
||||||
on:
|
|
||||||
push:
|
|
||||||
branches:
|
|
||||||
- main
|
|
||||||
pull_request:
|
|
||||||
branches:
|
|
||||||
- main
|
|
||||||
|
|
||||||
jobs:
|
|
||||||
build:
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
steps:
|
|
||||||
- uses: actions/checkout@v2
|
|
||||||
- name: Lint
|
|
||||||
run: |
|
|
||||||
npm ci
|
|
||||||
npm run lint
|
|
||||||
|
|
||||||
git diff
|
|
||||||
if [[ `git status --porcelain` ]]; then
|
|
||||||
exit 1
|
|
||||||
fi
|
|
||||||
|
|
@ -1,10 +1,21 @@
|
||||||
name: Build and deploy to GitHub Pages
|
name: Check, build and deploy to GitHub Pages
|
||||||
on:
|
on:
|
||||||
push:
|
push:
|
||||||
branches:
|
branches:
|
||||||
- main
|
- main
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
|
check:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v2
|
||||||
|
- name: Lint
|
||||||
|
run: |
|
||||||
|
npm ci
|
||||||
|
npm run lint && git diff
|
||||||
|
if [[ `git status --porcelain` ]]; then
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
build-and-deploy:
|
build-and-deploy:
|
||||||
concurrency: ci-${{ github.ref }}
|
concurrency: ci-${{ github.ref }}
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
Loading…
Add table
Add a link
Reference in a new issue