@@ -31,41 +31,17 @@ jobs:
3131 RUFF_VERSION=$(awk -F'[="]' '/\[project\.optional-dependencies\]/ {p=1} /ruff/ {if (p) print $4}' pyproject.toml)
3232 echo "RUFF_VERSION=$RUFF_VERSION" >> $GITHUB_ENV
3333
34- - name : Install Ruff
35- run : >
36- curl --no-progress-meter --location --fail
37- --proto '=https' --tlsv1.2
38- --write-out "%{stderr}Downloaded: %{url}\n"
39- "https://astral.sh/ruff/$RUFF_VERSION/install.sh"
40- | sh
34+ - name : Install Ruff ${{ env.RUFF_VERSION }}
35+ uses : astral-sh/ruff-action@v3
36+ with :
37+ args : --version
38+ version : ${{ env.RUFF_VERSION }}
4139
4240 - name : Lint with Ruff
43- run : ruff check . --output-format github
41+ run : ruff check --output-format= github
4442
4543 - name : Format with Ruff
46- run : ruff format . --diff
47-
48- flake8 :
49- runs-on : ubuntu-latest
50-
51- steps :
52- - uses : actions/checkout@v4
53- with :
54- persist-credentials : false
55- - name : Set up Python
56- uses : actions/setup-python@v5
57- with :
58- python-version : " 3"
59- - name : Install uv
60- run : >
61- curl --no-progress-meter --location --fail
62- --proto '=https' --tlsv1.2
63- "https://astral.sh/uv/install.sh"
64- | sh
65- - name : Install dependencies
66- run : uv pip install --upgrade "flake8>=6.0"
67- - name : Lint with flake8
68- run : flake8 .
44+ run : ruff format --diff
6945
7046 mypy :
7147 runs-on : ubuntu-latest
@@ -79,11 +55,10 @@ jobs:
7955 with :
8056 python-version : " 3"
8157 - name : Install uv
82- run : >
83- curl --no-progress-meter --location --fail
84- --proto '=https' --tlsv1.2
85- "https://astral.sh/uv/install.sh"
86- | sh
58+ uses : astral-sh/setup-uv@v5
59+ with :
60+ version : latest
61+ enable-cache : false
8762 - name : Install dependencies
8863 run : uv pip install ".[lint,test]"
8964 - name : Type check with mypy
@@ -101,11 +76,10 @@ jobs:
10176 with :
10277 python-version : " 3"
10378 - name : Install uv
104- run : >
105- curl --no-progress-meter --location --fail
106- --proto '=https' --tlsv1.2
107- "https://astral.sh/uv/install.sh"
108- | sh
79+ uses : astral-sh/setup-uv@v5
80+ with :
81+ version : latest
82+ enable-cache : false
10983 - name : Install dependencies
11084 run : uv pip install ".[lint,test]"
11185 - name : Type check with pyright
@@ -123,11 +97,10 @@ jobs:
12397 with :
12498 python-version : " 3"
12599 - name : Install uv
126- run : >
127- curl --no-progress-meter --location --fail
128- --proto '=https' --tlsv1.2
129- "https://astral.sh/uv/install.sh"
130- | sh
100+ uses : astral-sh/setup-uv@v5
101+ with :
102+ version : latest
103+ enable-cache : false
131104 - name : Install dependencies
132105 run : uv pip install --upgrade sphinx-lint
133106 - name : Lint documentation with sphinx-lint
@@ -145,11 +118,10 @@ jobs:
145118 with :
146119 python-version : " 3"
147120 - name : Install uv
148- run : >
149- curl --no-progress-meter --location --fail
150- --proto '=https' --tlsv1.2
151- "https://astral.sh/uv/install.sh"
152- | sh
121+ uses : astral-sh/setup-uv@v5
122+ with :
123+ version : latest
124+ enable-cache : false
153125 - name : Install dependencies
154126 run : uv pip install --upgrade twine build
155127 - name : Lint with twine
0 commit comments