From 4420e155cce9471536c568daffb87049e6a29f4d Mon Sep 17 00:00:00 2001 From: Yuriy Novostavskiy Date: Tue, 7 Jan 2025 23:16:07 +0000 Subject: [PATCH] move linters to separate job to run linters for dirrect commit to develop branch It's squashed commit of: abe0e8b67f2e36388fb9781fdfb7624c1cd0d109 df3edcf3866d92f36c4f1fa34fcfac6ce2087dd0 --- .github/workflows/compile.yml | 21 +-------------------- .github/workflows/linters.yml | 28 ++++++++++++++++++++++++++++ 2 files changed, 29 insertions(+), 20 deletions(-) create mode 100644 .github/workflows/linters.yml diff --git a/.github/workflows/compile.yml b/.github/workflows/compile.yml index 504fa8b5..6030e36d 100644 --- a/.github/workflows/compile.yml +++ b/.github/workflows/compile.yml @@ -1,4 +1,4 @@ - name: ๐Ÿ—๏ธ Compile Firmware + Lint Check + name: ๐Ÿ—๏ธ Compile Firmware on: pull_request: types: [ opened, synchronize, reopened ] @@ -85,22 +85,3 @@ with: name: updater.bin path: ${{ github.workspace }}/updater.bin - check_flasher: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v4 - - name: Check flasher with proof-html - uses: anishathalye/proof-html@v2 - with: - directory: ${{ github.workspace }}/flasher - run_black: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v4 - - name: Run Black in the check mode - uses: psf/black@stable - with: - options: "--check --verbose --line-length 120 --diff --color --target-version py312" - src: ${{ github.workspace }}/deploy - version: "~= 24.0" - diff --git a/.github/workflows/linters.yml b/.github/workflows/linters.yml new file mode 100644 index 00000000..e4378981 --- /dev/null +++ b/.github/workflows/linters.yml @@ -0,0 +1,28 @@ +name: ๐Ÿงน Lint Check +on: + push: + branches: + - develop + pull_request: + types: [ opened, synchronize, reopened ] + branches: + - develop +jobs: + check_flasher: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + - name: Check flasher with proof-html + uses: anishathalye/proof-html@v2 + with: + directory: ${{ github.workspace }}/flasher + run_black: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + - name: Run Black in the check mode + uses: psf/black@stable + with: + options: "--check --verbose --line-length 120 --diff --color --target-version py312" + src: ${{ github.workspace }}/deploy + version: "~= 24.0" \ No newline at end of file