Skip to content

Commit

Permalink
add eslint to github workflow
Browse files Browse the repository at this point in the history
- convert to using `yarn` directly to run prettier too with dependency caching

maybe
  • Loading branch information
TheAfroOfDoom committed Dec 29, 2023
1 parent 15a842e commit 8635f5a
Showing 1 changed file with 28 additions and 7 deletions.
35 changes: 28 additions & 7 deletions .github/workflows/scripts.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,14 +7,35 @@ on:
- main

jobs:
prettier:
format:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3
- uses: actions/checkout@v4
- name: Install Yarn 3.6.3
run: corepack enable
- name: Setup cache
uses: actions/setup-node@v4
with:
cache: 'yarn'
cache-dependency-path: yarn.lock
node-version-file: package.json
- run: yarn
- name: Run Prettier
uses: creyD/[email protected]
run: yarn start lint.prettier.check

lint:
runs-on: ubuntu-latest
needs: format
steps:
- uses: actions/checkout@v4
- name: Install Yarn 3.6.3
run: corepack enable
- name: Setup cache
uses: actions/setup-node@v4
with:
dry: True
prettier_options: '--check .'
prettier_version: 3.1.1
cache: 'yarn'
cache-dependency-path: yarn.lock
node-version-file: package.json
- run: yarn
- name: Run ESLint
run: yarn start lint.eslint.check

0 comments on commit 8635f5a

Please sign in to comment.