Adapters and tools for lintrunner
Project description
lintrunner-adapters
Adapters and tools for lintrunner.
lintrunner-adapters
currently supports popular Python and Rust linters and formatters like flake8
, pylint
, mypy
, black
, ruff
(with auto-fix support), rustfmt
, clippy
and many more - and the list is growing. Contribution is welcome!
To see the list of supported linters and formatters, run lintrunner_adapters run
.
Install
pip install lintrunner-adapters
Usage
Usage: python -m lintrunner_adapters [OPTIONS] COMMAND [ARGS]...
Options:
--help Show this message and exit.
Commands:
run Run an adapter.
to-sarif Convert the output of lintrunner json (INPUT) to SARIF (OUTPUT).
Use lintrunner_adapters run
to see a list of adapters available.
GitHub action
https://github.com/justinchuby/lintrunner-action
How to
Use lintrunner_adapters
with lintrunner
in your project
Refer to the .lintrunner.toml
config file in this repo and example configs for each adapter under examples/adapters
.
Write lint config in .lintrunner.toml
See https://docs.rs/lintrunner/latest/lintrunner/lint_config/struct.LintConfig.html.
Create a new adapter
Use lintrunner_adapters/adapters/pylint_linter.py
as an example.
Run lintrunner in CI and get Github code scanning messages in your PRs
Option 1
Use a GitHub Action: lintrunner-action
Option 2
Run it directly in the workflow. See .github/workflows/ci.yml
.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
File details
Details for the file lintrunner_adapters-0.12.0.tar.gz
.
File metadata
- Download URL: lintrunner_adapters-0.12.0.tar.gz
- Upload date:
- Size: 28.9 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.11.6
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 53d464dff494f7f364e013a20d3b7ea405a7f9459852eb5e7813a6428943ba15 |
|
MD5 | 0865e98215c59c5075a995eb7de9aa6d |
|
BLAKE2b-256 | 571bfb39c9124d7676c1bc30e517e8e4d387ecc40201ca994c41f02bf86301d5 |
File details
Details for the file lintrunner_adapters-0.12.0-py3-none-any.whl
.
File metadata
- Download URL: lintrunner_adapters-0.12.0-py3-none-any.whl
- Upload date:
- Size: 62.0 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.11.6
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 5c6989198fcf3b1ae1e15fda30589743176f5a13dda4b9d269dafdeff9747a9f |
|
MD5 | 865f48c51cc9eb456b9168f6fd0c3713 |
|
BLAKE2b-256 | 21f703b6f6fcc13119fba412d3d5791d5d5f5d72f86085d4a5bddbe7163311fe |