From 50467b85fdd478a1352ffc9d86cda0b9f2c8c385 Mon Sep 17 00:00:00 2001 From: Luan Citta Date: Wed, 5 Jun 2024 12:15:39 +0100 Subject: [PATCH] create custom workflow --- .github/workflows/Flake8.yml | 30 ++++++++++++++++++++++++++++++ .github/workflows/pylint.yml | 23 ----------------------- 2 files changed, 30 insertions(+), 23 deletions(-) create mode 100644 .github/workflows/Flake8.yml delete mode 100644 .github/workflows/pylint.yml diff --git a/.github/workflows/Flake8.yml b/.github/workflows/Flake8.yml new file mode 100644 index 0000000..0a2663d --- /dev/null +++ b/.github/workflows/Flake8.yml @@ -0,0 +1,30 @@ +name: Flake8 Linting + +on: [push] + +jobs: + build: + runs-on: ubuntu-latest + strategy: + matrix: + python-version: ["3.10"] + steps: + - uses: actions/checkout@v4 + + - name: Set up Python ${{ matrix.python-version }} + uses: actions/setup-python@v3 + with: + python-version: ${{ matrix.python-version }} + + - name: Install dependencies + run: | + python -m pip install --upgrade pip + pip install flake8 + + - name: Copy .flake8 config + run: | + cp .flake8 ${HOME}/.flake8 + + - name: Run flake8 + run: | + flake8 $(git ls-files '*.py') diff --git a/.github/workflows/pylint.yml b/.github/workflows/pylint.yml deleted file mode 100644 index c73e032..0000000 --- a/.github/workflows/pylint.yml +++ /dev/null @@ -1,23 +0,0 @@ -name: Pylint - -on: [push] - -jobs: - build: - runs-on: ubuntu-latest - strategy: - matrix: - python-version: ["3.8", "3.9", "3.10"] - steps: - - uses: actions/checkout@v4 - - name: Set up Python ${{ matrix.python-version }} - uses: actions/setup-python@v3 - with: - python-version: ${{ matrix.python-version }} - - name: Install dependencies - run: | - python -m pip install --upgrade pip - pip install pylint - - name: Analysing the code with pylint - run: | - pylint $(git ls-files '*.py')