From cde8c43e0c3e18908efdb6ae47ca8bb35b9d59c9 Mon Sep 17 00:00:00 2001 From: chris48s Date: Mon, 9 Dec 2024 09:11:41 +0000 Subject: [PATCH] tweak ruff scripts (#294) --- .circleci/config.yml | 3 +-- scripts/{format.sh => code-check.sh} | 1 + scripts/code-format.sh | 5 +++++ scripts/lint.sh | 4 ---- 4 files changed, 7 insertions(+), 6 deletions(-) rename scripts/{format.sh => code-check.sh} (75%) create mode 100755 scripts/code-format.sh delete mode 100755 scripts/lint.sh diff --git a/.circleci/config.yml b/.circleci/config.yml index f5ad1dcc..7aa1aded 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -26,8 +26,7 @@ jobs: command: | uv sync --dev --no-python-downloads - - run: ./scripts/lint.sh - - run: ./scripts/format.sh + - run: ./scripts/code-check.sh - run: make lambda-layers/DependenciesLayer/requirements.txt - run: npm install - run: npm run build diff --git a/scripts/format.sh b/scripts/code-check.sh similarity index 75% rename from scripts/format.sh rename to scripts/code-check.sh index ac3fe061..bbcec20b 100755 --- a/scripts/format.sh +++ b/scripts/code-check.sh @@ -2,3 +2,4 @@ set -euxo pipefail uv run ruff format . --check +uv run ruff check . diff --git a/scripts/code-format.sh b/scripts/code-format.sh new file mode 100755 index 00000000..e460402d --- /dev/null +++ b/scripts/code-format.sh @@ -0,0 +1,5 @@ +#!/bin/bash +set -euxo pipefail + +uv run ruff format . +uv run ruff check . --fix diff --git a/scripts/lint.sh b/scripts/lint.sh deleted file mode 100755 index af649f0e..00000000 --- a/scripts/lint.sh +++ /dev/null @@ -1,4 +0,0 @@ -#!/bin/bash -set -euxo pipefail - -uv run ruff check .