Skip to content

Commit

Permalink
Merge pull request #444 from CaioCintra/github-workflows
Browse files Browse the repository at this point in the history
standardizing github workflows and consoldiating frontend check
  • Loading branch information
andrewtavis authored Oct 15, 2023
2 parents 9a10853 + fd8b333 commit 7ca2da8
Show file tree
Hide file tree
Showing 3 changed files with 46 additions and 67 deletions.
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: pr_backend_formatting_check
name: pr_ci_backend
on:
pull_request_target:
branches:
Expand All @@ -10,7 +10,7 @@ on:
- completed

jobs:
python:
backend:
name: Run PR Backend Formatting Check
runs-on: ubuntu-latest
steps:
Expand All @@ -27,13 +27,13 @@ jobs:
python -m pip install --upgrade pip
pip install -r backend/requirements.txt
- name: Run Black
- name: Run Black - Formatting check
uses: psf/black@stable
with:
options: --check --verbose --exclude "migrations/"
src: ./backend

- name: Run ruff
- name: Run ruff - Linting and import sorting check
run: ruff ./backend

- name: Run mypy - Static Type Checking
Expand Down
Original file line number Diff line number Diff line change
@@ -1,29 +1,42 @@
name: pr_frontend_formatting_check
on:
pull_request_target:
branches:
- main
types: [opened, reopened, synchronize]
workflow_run:
workflows: [pr_maintainer_checklist]
types:
- completed

jobs:
prettier:
name: Run PR Frontend Formatting Check
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3

- name: Setup Node
uses: actions/setup-node@v3

- name: Install Prettier
run: npm install prettier

- name: Run Prettier
working-directory: ./frontend
run: |
npx prettier . --check --config ../.prettierrc --ignore-path ../.prettierignore
name: pr_ci_frontend
on:
pull_request_target:
branches:
- main
types: [opened, reopened, synchronize]
workflow_run:
workflows: [pr_maintainer_checklist]
types:
- completed

jobs:
frontend:
name: Run PR Frontend Formatting Check
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3

- name: Setup Node
uses: actions/setup-node@v3

- name: Yarn Install
uses: borales/actions-yarn@v4
with:
cmd: install
dir: "frontend"

- name: Install Prettier
run: yarn add prettier

- name: Run Prettier
working-directory: ./frontend
run: |
yarn prettier . --check --config ../.prettierrc --ignore-path ../.prettierignore
continue-on-error: true

- name: Run Type Check
uses: borales/actions-yarn@v4
with:
cmd: nuxi typecheck
dir: "frontend"
34 changes: 0 additions & 34 deletions .github/workflows/pr_ts_typecheck.yaml

This file was deleted.

0 comments on commit 7ca2da8

Please sign in to comment.