Skip to content

ci(github-actions): minor improvements #908

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 3 commits into from
Apr 30, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
33 changes: 31 additions & 2 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,35 @@ name: CI
on: ['push', 'pull_request']

jobs:
build:
name: Build
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v3
- name: Use Node.js 20.x
uses: actions/setup-node@v3
with:
node-version: 20.x

- uses: actions/cache@v3
id: yarn-cache # use this to check for `cache-hit` (`steps.yarn-cache.outputs.cache-hit != 'true'`)
with:
path: '**/node_modules'
key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
restore-keys: |
${{ runner.os }}-yarn-

- name: yarn install
if: steps.yarn-cache.outputs.cache-hit != 'true' # Over here!
run: yarn install --frozen-lockfile --ignore-scripts

- name: yarn build
run: yarn build

env:
CI: true

lint:
name: Lint
runs-on: ubuntu-latest
Expand Down Expand Up @@ -60,7 +89,7 @@ jobs:
run: yarn install --frozen-lockfile --ignore-scripts

- name: yarn test
run: yarn test --reporters="default" --reporters="github-actions"
run: yarn test --ci --reporters="default" --reporters="github-actions"

env:
CI: true
Expand Down Expand Up @@ -101,7 +130,7 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: streetsidesoftware/cspell-action@main
- uses: streetsidesoftware/cspell-action@v2
with:
# Github token used to fetch the list of changed files in the commit.
# Default: ${{ github.token }}
Expand Down