Skip to main content
Plugins / Ruff

Ruff

by Adam Lui
Website
code-qualityformattinglintingpythonruffsecurity

Run Ruff on your Python code.


Quick start

when:
  - event: manual
  - event: [pull_request, push]
    path: { include: ['**/*.{py,pyi}', '{pyproject,.ruff,ruff}.toml'] }

steps:
  - name: ruff
    image: adamlui/drone-ruff:v1.0.1

Settings (10)

NOTE  YAML settings override matching Ruff config file settings.

Lint example

  - name: ruff
    image: adamlui/drone-ruff:v1.0.1
    settings:
      src: ./src

Format example

  - name: ruff-format
    image: adamlui/drone-ruff:v1.0.1
    settings:
      src: ./src
      format: true
Ruff (5)
Setting Description Default
lint Run ruff check (linting). true
format Run ruff format (code formatting). false
args Additional raw args passed verbatim to the Ruff CLI. none
src Whitespace-separated list of files, directories, or glob patterns to lint/format. .
working_directory Directory to run Ruff from (alias root_dir). repo root
Findings (3)
Setting Description Default
output_format1 Lint findings output format (e.g. concise, full, gitlab, json). full
color Colorize findings. true
quiet1 Report errors only (suppress warnings and summary). false

1 Unreleased — to be introduced in v1.1.0.

Plugin (2)
Setting Description Default
debug Enable shell tracing (set -x) of the plugin entrypoint. false
never_fail Exit 0 regardless of lint errors (so CI step always passes). false

[Linted by Woodpecker / Ruff]

HTML

<a target="_blank" href="https://woodpecker-ci.org/plugins/ruff">
    <img height=33 alt="[Linted by Woodpecker / Ruff]" src="https://img.shields.io/badge/Linted_by-Woodpecker_%2F_Ruff-black?logo=drone&logoColor=white&labelColor=464646&style=for-the-badge"></a>

Markdown

[![[Linted by Woodpecker / Ruff]](https://img.shields.io/badge/Linted_by-Woodpecker_%2F_Ruff-black?logo=drone&logoColor=white&labelColor=464646&style=for-the-badge)](https://woodpecker-ci.org/plugins/ruff)