Skip to content

Use ruff instead of flake8 to lint files #234

Use ruff instead of flake8 to lint files

Use ruff instead of flake8 to lint files #234

Workflow file for this run

---
# MegaLinter GitHub Action configuration file
# More info at https://megalinter.io
name: MegaLinter
on:
push:
branches: main
pull_request:
jobs:
megalinter:
name: MegaLinter
runs-on: ubuntu-latest
permissions:
# Give the linter write permission to comment on PRs (if PR is not from fork)
issues: write
pull-requests: write
steps:
# Git Checkout
- name: Checkout Code
uses: actions/checkout@v4
with:
token: ${{ secrets.GITHUB_TOKEN }}
fetch-depth: 0
# MegaLinter
- name: MegaLinter
id: ml
# You can override MegaLinter flavor used to have faster performances
# More info at https://megalinter.io/flavors/
uses: oxsecurity/megalinter/flavors/python@v8
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
# Validate whole codebase on pushes and only changes on pull requests
# FIXME VALIDATE_ALL_CODEBASE: ${{ github.event_name == 'push'}}
VALIDATE_ALL_CODEBASE: true
LINTER_RULES_PATH: .
ENABLE_LINTERS: PYTHON_RUFF
PYTHON_RUFF_CONFIG_FILE: pyproject.toml
# Make workflow fail even on non blocking errors
FORMATTERS_DISABLE_ERRORS: false
# Upload MegaLinter artifacts
- name: Archive production artifacts
if: success() || failure()
uses: actions/upload-artifact@v4
with:
name: MegaLinter reports
path: |
megalinter-reports
mega-linter.log