mirror of
https://github.com/mandiant/capa.git
synced 2025-12-08 22:00:36 -08:00
ruff: update config
This commit is contained in:
49
.github/ruff.toml
vendored
49
.github/ruff.toml
vendored
@@ -1,10 +1,47 @@
|
||||
# Enable pycodestyle (`E`) codes
|
||||
select = ["E"]
|
||||
# Enable the pycodestyle (`E`) and Pyflakes (`F`) rules by default.
|
||||
# Unlike Flake8, Ruff doesn't enable pycodestyle warnings (`W`) or
|
||||
# McCabe complexity (`C901`) by default.
|
||||
select = ["E", "F"]
|
||||
|
||||
# Allow autofix for all enabled rules (when `--fix`) is provided.
|
||||
fixable = ["ALL"]
|
||||
unfixable = []
|
||||
|
||||
# E402 module level import not at top of file
|
||||
# E722 do not use bare 'except'
|
||||
ignore = ["E402", "E722"]
|
||||
exclude = ["*_pb2.py", "*_pb2.pyi"]
|
||||
# E501 line too long
|
||||
ignore = ["E402", "E722", "E501"]
|
||||
|
||||
# Same as pycodestyle.
|
||||
line-length = 180
|
||||
line-length = 120
|
||||
|
||||
exclude = [
|
||||
# Exclude a variety of commonly ignored directories.
|
||||
".bzr",
|
||||
".direnv",
|
||||
".eggs",
|
||||
".git",
|
||||
".git-rewrite",
|
||||
".hg",
|
||||
".mypy_cache",
|
||||
".nox",
|
||||
".pants.d",
|
||||
".pytype",
|
||||
".ruff_cache",
|
||||
".svn",
|
||||
".tox",
|
||||
".venv",
|
||||
"__pypackages__",
|
||||
"_build",
|
||||
"buck-out",
|
||||
"build",
|
||||
"dist",
|
||||
"node_modules",
|
||||
"venv",
|
||||
# protobuf generated files
|
||||
"*_pb2.py",
|
||||
"*_pb2.pyi"
|
||||
]
|
||||
|
||||
[per-file-ignores]
|
||||
#"__init__.py" = ["E402"]
|
||||
#"path/to/file.py" = ["E402"]
|
||||
|
||||
Reference in New Issue
Block a user