Skip to content

Commit 0038d4a

Browse files
authored
Create GitHub workflow (#11)
Basic ruff checks
2 parents a8f07f0 + bbb4548 commit 0038d4a

File tree

3 files changed

+40
-2
lines changed

3 files changed

+40
-2
lines changed

.github/workflows/python-app.yml

Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
# This workflow will install Python dependencies, run tests and lint with a single version of Python
2+
# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-python
3+
4+
name: Python application
5+
6+
on:
7+
push:
8+
branches: ["master"]
9+
pull_request:
10+
branches: ["master"]
11+
12+
permissions:
13+
contents: read
14+
15+
jobs:
16+
build:
17+
runs-on: ubuntu-latest
18+
19+
steps:
20+
# https://docs.astral.sh/uv/guides/integration/github/#setting-up-python
21+
- uses: actions/checkout@v4
22+
- name: Install uv
23+
uses: astral-sh/setup-uv@v4
24+
- name: "Set up Python"
25+
uses: actions/setup-python@v5
26+
with:
27+
python-version-file: "pyproject.toml"
28+
- name: Install the project
29+
run: uv sync --all-extras --dev
30+
# https://docs.astral.sh/ruff/integrations
31+
- name: Run Ruff
32+
run: uv run ruff check --output-format=github .
33+
- name: Run Format
34+
run: uv run ruff format --diff

linear/console.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -158,7 +158,7 @@ def description_text(description: str):
158158

159159
def issue_text(issue: Issue):
160160
text = title_text(issue)
161-
url = f"{Fore.GREEN}" f"{issue.url}" f"{Style.RESET_ALL}"
161+
url = f"{Fore.GREEN}{issue.url}{Style.RESET_ALL}"
162162
text += f"<{url}>\n"
163163

164164
if issue.description:
@@ -197,7 +197,6 @@ def issue_text(issue: Issue):
197197
comment_text += f" {reply.body}\n\n"
198198
text += f"\n{comment_text}\n"
199199

200-
201200
return text
202201

203202

pyproject.toml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,11 @@ li = "linear.cli:cli"
2121
[tool.pyright]
2222
venvPath = ".venv"
2323

24+
[tool.uv]
25+
dev-dependencies = [
26+
"ruff>=0.8.4",
27+
]
28+
2429
[build-system]
2530
requires = ["hatchling"]
2631
build-backend = "hatchling.build"

0 commit comments

Comments
 (0)