Skip to content

Commit 12ad293

Browse files
ci(workflows): separate ruff and ty linting into dedicated workflows
1 parent b7e51c5 commit 12ad293

3 files changed

Lines changed: 68 additions & 44 deletions

File tree

.github/workflows/lint.yml

Lines changed: 0 additions & 44 deletions
This file was deleted.

.github/workflows/ruff-lint.yml

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
name: Ruff Lint
2+
3+
on:
4+
push:
5+
branches: [ "master" ]
6+
pull_request:
7+
branches: [ "master" ]
8+
9+
permissions:
10+
contents: read
11+
12+
jobs:
13+
lint:
14+
runs-on: ubuntu-latest
15+
steps:
16+
- uses: actions/checkout@v6
17+
with:
18+
fetch-depth: 0
19+
20+
- name: Run Ruff check
21+
uses: astral-sh/ruff-action@v3
22+
with:
23+
python-version: "3.14" # Aligns with pyproject.toml
24+
args: check --output-format=github archipy
25+
26+
- name: Run Ruff format check
27+
uses: astral-sh/ruff-action@v3
28+
with:
29+
python-version: "3.14" # Aligns with pyproject.toml
30+
args: format --check archipy

.github/workflows/ty-lint.yml

Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,38 @@
1+
name: Ty Lint
2+
3+
on:
4+
push:
5+
branches: [ "master" ]
6+
pull_request:
7+
branches: [ "master" ]
8+
9+
permissions:
10+
contents: read
11+
12+
jobs:
13+
lint:
14+
runs-on: ubuntu-latest
15+
steps:
16+
- uses: actions/checkout@v6
17+
with:
18+
fetch-depth: 0
19+
20+
- name: Set up Python 3.14
21+
uses: actions/setup-python@v6
22+
with:
23+
python-version: "3.14" # From pyproject.toml
24+
25+
- name: Cache UV
26+
uses: actions/cache@v4
27+
with:
28+
path: ~/.cache/uv
29+
key: ${{ runner.os }}-uv-${{ hashFiles('**/pyproject.toml', '**/uv.lock') }}
30+
31+
- name: Install UV
32+
uses: astral-sh/setup-uv@v7
33+
34+
- name: Install dependencies
35+
run: uv sync --group dev # Follows pyproject.toml exactly
36+
37+
- name: Run Ty type checking
38+
run: uv run ty check archipy # Config from pyproject.toml

0 commit comments

Comments
 (0)