Thanks to visit codestin.com
Credit goes to github.com

Skip to content

A GitHub action that checks Python code using black and ruff

License

konstruktoid/action-pylint

Use this GitHub action with your project
Add this Action to an existing workflow or create a new one
View on Marketplace

Repository files navigation

Python linting and testing using black, ruff and ty

A GitHub action that checks Python code using black, ruff and ty.

Github Actions configuration examples

on: [push, pull_request]
name: Python linting

permissions:
  contents: read

jobs:
  PythonLinting:
    name: Python linting
    runs-on: ubuntu-latest
    steps:
      - name: Checkout repository
        uses: actions/checkout@v4

      - name: Python linting
        uses: konstruktoid/action-pylint@v2

Script

#!/bin/sh

set -euf

export PATH="${PATH}:/root/.local/bin"

black --check --diff --no-color --quiet .
ruff check --select ALL .
ty check .

Sponsor this project

 

Packages

No packages published

Contributors 6