-
Notifications
You must be signed in to change notification settings - Fork 905
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
9f37c11
commit b6808c5
Showing
1 changed file
with
49 additions
and
0 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,49 @@ | ||
|
||
on: [push, pull_request] | ||
|
||
jobs: | ||
checkout_code: | ||
runs-on: ubuntu-22.04 | ||
|
||
steps: | ||
- uses: actions/checkout@v3 | ||
- name: Save repository's content as artifact | ||
uses: actions/upload-artifact@v3 | ||
with: | ||
name: repo | ||
path: ${{ github.workspace }} | ||
|
||
v18: | ||
runs-on: ubuntu-22.04 | ||
needs: checkout_code | ||
container: | ||
image: "node:18-buster" | ||
steps: | ||
- name: Install sudo | ||
run: | | ||
apt update | ||
apt install -y sudo | ||
# workaround for https://github.com/actions/runner/issues/2033 | ||
- name: ownership workaround | ||
run: git config --global --add safe.directory '*' | ||
- name: Get repository's content | ||
uses: actions/download-artifact@v3 | ||
with: | ||
name: repo | ||
- uses: actions/cache@v3 | ||
with: | ||
path: node_modules | ||
key: v1-dependencies-${{ hashFiles('**/yarn.lock') }} | ||
restore-keys: | | ||
v1-dependencies-${{ hashFiles('**/yarn.lock') }} | ||
v1-dependencies- | ||
- name: Update yarn | ||
run: | | ||
node -v | ||
yarn global add yarn@latest | ||
- name: Install dependencies | ||
run: yarn install --ignore-engines --frozen-lockfile | ||
- name: Build packages | ||
run: yarn build | ||
- name: Test | ||
run: yarn test-ci |