From 6e66da4045e1ac0df2705876da99939c40d31380 Mon Sep 17 00:00:00 2001 From: Sonny Bakker Date: Thu, 27 Feb 2025 21:38:48 +0100 Subject: [PATCH 1/2] Remove isort configuration Is replaced by ruff --- .isort.cfg | 10 ---------- pyproject.toml | 19 ++++++++++++++++++- 2 files changed, 18 insertions(+), 11 deletions(-) delete mode 100644 .isort.cfg diff --git a/.isort.cfg b/.isort.cfg deleted file mode 100644 index 9327a6a..0000000 --- a/.isort.cfg +++ /dev/null @@ -1,10 +0,0 @@ -[settings] -include_trailing_comma = true -line_length = 88 -multi_line_output = 3 -skip = env/, venv/ -default_section = THIRDPARTY -known_first_party = transip_client -sections = FUTURE,STDLIB,THIRDPARTY,FIRSTPARTY,LOCALFOLDER -lines_between_types=1 -lines_after_imports=2 diff --git a/pyproject.toml b/pyproject.toml index 533b693..6f2039e 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -14,7 +14,7 @@ dependencies = [ [project.optional-dependencies] development = [ - "ruff>=0.8.6", + 'ruff>=0.8.6', ] ci = ['coverage>=5.3.1'] @@ -29,3 +29,20 @@ transip-listen = 'transip_client.cli:run' [build-system] requires = ['setuptools'] build-backend = 'setuptools.build_meta' + +[tool.uv] +environments = ["sys_platform == 'linux'"] + +[tool.ruff.lint.isort] +lines-between-types=1 +lines-after-imports=2 + +default-section = 'third-party' +known-first-party = ['transip_client'] +section-order = [ + 'future', + 'standard-library', + 'third-party', + 'first-party', + 'local-folder', +] From c4fb34629a4bd03b8081be254fb64fc6a60747e6 Mon Sep 17 00:00:00 2001 From: Sonny Bakker Date: Thu, 27 Feb 2025 21:39:29 +0100 Subject: [PATCH 2/2] Remove build CI jobs & add formatting job --- .woodpecker/build.yaml | 13 ------------- .woodpecker/tests.yaml | 5 +++++ 2 files changed, 5 insertions(+), 13 deletions(-) delete mode 100644 .woodpecker/build.yaml diff --git a/.woodpecker/build.yaml b/.woodpecker/build.yaml deleted file mode 100644 index 2cfd1df..0000000 --- a/.woodpecker/build.yaml +++ /dev/null @@ -1,13 +0,0 @@ -when: - - event: push - -steps: - - name: development build - image: ghcr.io/astral-sh/uv:python3.11-bookworm - commands: - - uv run -- transip-listen --help - - - name: production build - image: ghcr.io/astral-sh/uv:python3.11-bookworm - commands: - - uv run -- transip-listen --help diff --git a/.woodpecker/tests.yaml b/.woodpecker/tests.yaml index d18736d..cc9abd7 100644 --- a/.woodpecker/tests.yaml +++ b/.woodpecker/tests.yaml @@ -8,3 +8,8 @@ steps: - uv sync --extra ci - uv run -- coverage run --module unittest - uv run -- coverage report + + - name: code formatting + image: ghcr.io/astral-sh/uv:python3.11-bookworm + commands: + - uv run -- ruff format --diff