File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1- name : Reusable Lint Workflow
2-
3- on :
4- workflow_call :
5- inputs :
6- clang-format-version :
7- description : ' Version of clang-format to use'
8- required : false
9- type : string
10- default : ' '
1+ # Requires
2+ # - pyproject.toml with a group called "lint" which must include prek
3+ # - A prek.toml file
4+ name : Lint workflow for tskit-dev
115
126jobs :
13- pre-commit :
7+ prek :
148 name : Lint
159 runs-on : ubuntu-24.04
1610 steps :
@@ -21,12 +15,14 @@ jobs:
2115
2216 - uses : actions/checkout@v4.2.2
2317
24- - uses : actions/setup-python@v5.4.0
18+ - name : Install uv and set the python version
19+ uses : astral-sh/setup-uv@v6
2520 with :
26- python-version : ' 3.12'
21+ python-version : 3.11
22+ version : " 0.8.15"
23+
24+ - name : Install Python dependencies
25+ run : uv sync --locked --only-group lint
2726
28- - name : Install clang-format (if needed)
29- if : ${{ inputs.clang-format-version != '' }}
30- run : pip install clang-format==${{ inputs.clang-format-version }}
31-
32- - uses : pre-commit/action@v3.0.1
27+ - name : Run prek
28+ run : uv run --only-group lint prek -c prek.toml run --all-files
You can’t perform that action at this time.
0 commit comments