feat: 👷 seperate lint jobs for fe & be

This commit is contained in:
ThatOneCalculator 2024-01-04 17:18:20 -08:00
parent 9d3652db58
commit 0b1dd21a30
No known key found for this signature in database
GPG Key ID: 8703CACD01000000
4 changed files with 49 additions and 7 deletions

View File

@ -5,7 +5,7 @@ on:
pull_request: pull_request:
jobs: jobs:
build: build:
name: 'Format Backend' # Format & Lint name: 'Format Backend'
env: env:
PUBLIC_API_BASE_URL: '' PUBLIC_API_BASE_URL: ''
runs-on: ubuntu-latest runs-on: ubuntu-latest
@ -23,8 +23,5 @@ jobs:
run: | run: |
python -m pip install --upgrade pip python -m pip install --upgrade pip
pip install yapf pip install yapf
# pip install pylint
# - name: Lint backend
# run: bun run lint:backend
- name: Format backend - name: Format backend
run: bun run format:backend run: bun run format:backend

View File

@ -5,7 +5,7 @@ on:
pull_request: pull_request:
jobs: jobs:
build: build:
name: 'Format & Build Frontend' # Format, Lint, & Build name: 'Format & Build Frontend'
env: env:
PUBLIC_API_BASE_URL: '' PUBLIC_API_BASE_URL: ''
runs-on: ubuntu-latest runs-on: ubuntu-latest
@ -16,8 +16,6 @@ jobs:
- run: bun --version - run: bun --version
- name: Install frontend dependencies - name: Install frontend dependencies
run: bun install --frozen-lockfile run: bun install --frozen-lockfile
# - run: bun run lint
# - run: bun run lint:types
- name: Format frontend - name: Format frontend
run: bun run format run: bun run format
- name: Build frontend - name: Build frontend

27
.github/workflows/lint-backend.yaml vendored Normal file
View File

@ -0,0 +1,27 @@
name: Python CI
on:
push:
branches: ['main']
pull_request:
jobs:
build:
name: 'Lint Backend'
env:
PUBLIC_API_BASE_URL: ''
runs-on: ubuntu-latest
strategy:
matrix:
node-version:
- latest
steps:
- uses: actions/checkout@v4
- name: Use Python
uses: actions/setup-python@v4
- name: Use Bun
uses: oven-sh/setup-bun@v1
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install pylint
- name: Lint backend
run: bun run lint:backend

20
.github/workflows/lint-frontend.yaml vendored Normal file
View File

@ -0,0 +1,20 @@
name: Bun CI
on:
push:
branches: ['main']
pull_request:
jobs:
build:
name: 'Lint Frontend'
env:
PUBLIC_API_BASE_URL: ''
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Use Bun
uses: oven-sh/setup-bun@v1
- run: bun --version
- name: Install frontend dependencies
run: bun install --frozen-lockfile
- run: bun run lint
- run: bun run lint:types