-
Notifications
You must be signed in to change notification settings - Fork 26
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Just for `next` branch for now.
- Loading branch information
Showing
2 changed files
with
109 additions
and
2 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,107 @@ | ||
name: ci | ||
|
||
on: | ||
push: | ||
branches: [next] | ||
pull_request: | ||
branches: [next] | ||
|
||
env: | ||
yarn-cache-name: yarn-cache | ||
yarn-cache-path: .yarn | ||
|
||
jobs: | ||
check-lockfile: | ||
runs-on: ubuntu-latest | ||
strategy: | ||
matrix: | ||
node-version: [18.x] | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- name: Use Node.js ${{ matrix.node-version }} | ||
uses: actions/setup-node@v3 | ||
with: | ||
node-version: ${{ matrix.node-version }} | ||
- name: Use or update Yarn cache | ||
uses: actions/cache@v3 | ||
with: | ||
path: ${{ env.yarn-cache-path }} | ||
key: ${{ matrix.node-version }}-${{ env.yarn-cache-name }}-${{ hashFiles('**/yarn.lock') }} | ||
- run: yarn --cache-folder=${{ env.yarn-cache-path }} | ||
- run: git diff --quiet -- yarn.lock | ||
|
||
format-check: | ||
runs-on: ubuntu-latest | ||
strategy: | ||
matrix: | ||
node-version: [14.x] | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- name: Use Node.js ${{ matrix.node-version }} | ||
uses: actions/setup-node@v3 | ||
with: | ||
node-version: ${{ matrix.node-version }} | ||
- name: Use or update Yarn cache | ||
uses: actions/cache@v3 | ||
with: | ||
path: ${{ env.yarn-cache-path }} | ||
key: ${{ matrix.node-version }}-${{ env.yarn-cache-name }}-${{ hashFiles('**/yarn.lock') }} | ||
- run: yarn --cache-folder=${{ env.yarn-cache-path }} --frozen-lockfile | ||
- run: yarn --cache-folder=${{ env.yarn-cache-path }} format:check | ||
|
||
lint: | ||
runs-on: ubuntu-latest | ||
strategy: | ||
matrix: | ||
node-version: [14.x] | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- name: Use Node.js ${{ matrix.node-version }} | ||
uses: actions/setup-node@v3 | ||
with: | ||
node-version: ${{ matrix.node-version }} | ||
- name: Use or update Yarn cache | ||
uses: actions/cache@v3 | ||
with: | ||
path: ${{ env.yarn-cache-path }} | ||
key: ${{ matrix.node-version }}-${{ env.yarn-cache-name }}-${{ hashFiles('**/yarn.lock') }} | ||
- run: yarn --cache-folder=${{ env.yarn-cache-path }} --frozen-lockfile | ||
- run: yarn --cache-folder=${{ env.yarn-cache-path }} lint | ||
|
||
build: | ||
runs-on: ubuntu-latest | ||
strategy: | ||
matrix: | ||
node-version: [18.x] | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- name: Use Node.js ${{ matrix.node-version }} | ||
uses: actions/setup-node@v3 | ||
with: | ||
node-version: ${{ matrix.node-version }} | ||
- name: Use or update Yarn cache | ||
uses: actions/cache@v3 | ||
with: | ||
path: ${{ env.yarn-cache-path }} | ||
key: ${{ matrix.node-version }}-${{ env.yarn-cache-name }}-${{ hashFiles('**/yarn.lock') }} | ||
- run: yarn --cache-folder=${{ env.yarn-cache-path }} --frozen-lockfile | ||
- run: yarn --cache-folder=${{ env.yarn-cache-path }} build | ||
|
||
test: | ||
runs-on: ubuntu-latest | ||
strategy: | ||
matrix: | ||
node-version: [18.x] | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- name: Use Node.js ${{ matrix.node-version }} | ||
uses: actions/setup-node@v3 | ||
with: | ||
node-version: ${{ matrix.node-version }} | ||
- name: Use or update Yarn cache | ||
uses: actions/cache@v3 | ||
with: | ||
path: ${{ env.yarn-cache-path }} | ||
key: ${{ matrix.node-version }}-${{ env.yarn-cache-name }}-${{ hashFiles('**/yarn.lock') }} | ||
- run: yarn --cache-folder=${{ env.yarn-cache-path }} --frozen-lockfile | ||
- run: yarn --cache-folder=${{ env.yarn-cache-path }} test |
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