From 6dd940777a3a6734c536096558b382faeaea2002 Mon Sep 17 00:00:00 2001 From: Matt McCormick Date: Fri, 12 Mar 2021 09:57:03 -0500 Subject: [PATCH] STYLE: Add black, flake8 GitHub Action linters --- .github/workflows/clang-format-linter.yml | 13 ---------- .github/workflows/lint.yml | 29 +++++++++++++++++++++++ 2 files changed, 29 insertions(+), 13 deletions(-) delete mode 100644 .github/workflows/clang-format-linter.yml create mode 100644 .github/workflows/lint.yml diff --git a/.github/workflows/clang-format-linter.yml b/.github/workflows/clang-format-linter.yml deleted file mode 100644 index 69166d961..000000000 --- a/.github/workflows/clang-format-linter.yml +++ /dev/null @@ -1,13 +0,0 @@ -name: clang-format linter - -on: [push,pull_request] - -jobs: - lint: - runs-on: ubuntu-latest - - steps: - - uses: actions/checkout@v1 - with: - fetch-depth: 1 - - uses: InsightSoftwareConsortium/ITKClangFormatLinterAction@master diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml new file mode 100644 index 000000000..c7b77db93 --- /dev/null +++ b/.github/workflows/lint.yml @@ -0,0 +1,29 @@ +name: Lint + +on: [push,pull_request] + +jobs: + lint: + runs-on: ubuntu-latest + + steps: + - uses: actions/checkout@v1 + with: + fetch-depth: 1 + + - name: Lint C++ + uses: InsightSoftwareConsortium/ITKClangFormatLinterAction@master + + - name: Set up Python + uses: actions/setup-python@v1 + with: + python-version: 3.9 + + - name: Install Python dependencies + run: pip install black + + - name: Lint Python + uses: wearerequired/lint-action@v1 + with: + black: true + black_dir: src/