diff --git a/.github/workflows/black.yml b/.github/workflows/black.yml deleted file mode 100644 index fd65518..0000000 --- a/.github/workflows/black.yml +++ /dev/null @@ -1,25 +0,0 @@ -name: Python code style check with black - -on: [push] - -# only one run per PR/branch happens at a time, cancelling the old run when a new one starts -concurrency: - group: ${{ github.workflow }}-${{ github.ref }} - cancel-in-progress: true - -jobs: - black: - - runs-on: ubuntu-22.04 - - steps: - - uses: actions/checkout@v4 - - name: Install apt dependencies - run: | - sudo apt-get update && sudo apt-get install python3 python3-pip -y - - name: Install pip dependencies - run: | - pip3 install black==23.1.0 - - name: Check code style with Black - run: | - black --check --diff --line-length 79 . diff --git a/.github/workflows/flake8.yml b/.github/workflows/flake8.yml deleted file mode 100644 index 03141ae..0000000 --- a/.github/workflows/flake8.yml +++ /dev/null @@ -1,26 +0,0 @@ -name: Python Flake8 Code Quality - -on: [push] - -# only one run per PR/branch happens at a time, cancelling the old run when a new one starts -concurrency: - group: ${{ github.workflow }}-${{ github.ref }} - cancel-in-progress: true - -jobs: - - flake8-actinia: - runs-on: ubuntu-22.04 - steps: - - uses: actions/checkout@v4 - - name: Set up Python - uses: actions/setup-python@v5 - with: - python-version: 3.8 - - name: Install - run: | - python -m pip install --upgrade pip - pip install flake8==3.8.0 - - name: Run Flake8 - run: | - flake8 --config=.flake8 --count --statistics --show-source --jobs=$(nproc) . diff --git a/.github/workflows/linting.yml b/.github/workflows/linting.yml new file mode 100644 index 0000000..adab353 --- /dev/null +++ b/.github/workflows/linting.yml @@ -0,0 +1,11 @@ +name: Linting and code quality check + +on: [push, pull_request] + +jobs: + lint: + uses: mundialis/github-workflows/.github/workflows/linting.yml@main + with: + # set pylint-version to empty string to skip the pylint workflow + pylint-version: '' + BASH_SEVERITY: 'warning' \ No newline at end of file diff --git a/.github/workflows/super-linter.yml b/.github/workflows/super-linter.yml deleted file mode 100644 index c85e40c..0000000 --- a/.github/workflows/super-linter.yml +++ /dev/null @@ -1,37 +0,0 @@ -name: General linting - -on: [push] - -# only one run per PR/branch happens at a time, cancelling the old run when a new one starts -concurrency: - group: ${{ github.workflow }}-${{ github.ref }} - cancel-in-progress: true - -jobs: - super-linter: - name: GitHub Super Linter - - runs-on: ubuntu-latest - - steps: - - uses: actions/checkout@v4 - - name: Lint code base - uses: github/super-linter@v5 - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - # Listed but commented out linters would be nice to have. - # (see https://github.com/github/super-linter#environment-variables) - # - # Python (supported using Pylint) and C/C++ (not supported) are - # handled separately due to the complexity of the settings. - # VALIDATE_BASH: true - # VALIDATE_CSS: true - # VALIDATE_DOCKER: true - VALIDATE_JAVASCRIPT_ES: true - # VALIDATE_JAVASCRIPT_STANDARD: true - VALIDATE_JSON: true - VALIDATE_MARKDOWN: true - VALIDATE_POWERSHELL: true - # VALIDATE_XML: true - VALIDATE_YAML: true - FILTER_REGEX_EXCLUDE: ./config/templates/