From fc026565b33a13e1bc4d7901177200955d1a7687 Mon Sep 17 00:00:00 2001 From: derekpierre Date: Mon, 18 Sep 2023 09:16:42 -0400 Subject: [PATCH] Add darker to github workflow; also update version of darker used in pre-commit hook. --- .github/workflows/darker.yml | 17 +++++++++++++++++ .github/workflows/tests.yml | 2 +- .pre-commit-config.yaml | 4 ++-- 3 files changed, 20 insertions(+), 3 deletions(-) create mode 100644 .github/workflows/darker.yml diff --git a/.github/workflows/darker.yml b/.github/workflows/darker.yml new file mode 100644 index 0000000..7c27f18 --- /dev/null +++ b/.github/workflows/darker.yml @@ -0,0 +1,17 @@ +name: 🧹 Darker + +on: [push, pull_request] + +jobs: + lint: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3 + with: + fetch-depth: 0 + - uses: actions/setup-python@v4 + with: + python-version: '3.8' + - uses: akaihola/darker@1.7.2 + with: + version: "1.7.2" # defaults to same version, but can be modified diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index eb43cde..c562ebe 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -15,7 +15,7 @@ jobs: python-version: ["3.8", "3.10"] steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v3 - name: Set up Python ${{ matrix.python-version }} uses: actions/setup-python@v4 diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 0e9d49d..9f393a8 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -39,9 +39,9 @@ repos: - repo: https://github.com/akaihola/darker - rev: 1.6.1 + rev: 1.7.2 hooks: - id: darker args: [--isort] additional_dependencies: - - isort~=5.9 + - isort~=5.9