diff --git a/.github/workflows/code_quality.yml b/.github/workflows/code_quality.yml new file mode 100644 index 0000000..c133c51 --- /dev/null +++ b/.github/workflows/code_quality.yml @@ -0,0 +1,34 @@ +name: Code Quality + +on: + pull_request: + branches: [ main ] + push: + branches: [ main ] + +jobs: + lint-and-type-check: + name: Lint and Type Check + runs-on: ubuntu-latest + + steps: + - name: Checkout code + uses: actions/checkout@v4 + with: + fetch-depth: 0 + + - name: Set up Python + uses: actions/setup-python@v5 + with: + python-version: '3.12' + cache: 'pip' + + - name: Install dependencies + run: | + python -m pip install --upgrade pip + pip install -e ".[dev]" + + - name: Run pre-commit hooks + uses: pre-commit/action@v3.0.1 + with: + extra_args: --all-files --verbose