加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
克隆/下载
.ruff.toml 1.44 KB
一键复制 编辑 原始数据 按行查看 历史
# https://docs.astral.sh/ruff/settings/
# Exclude a variety of commonly ignored directories.
exclude = [
".eggs",
".git",
"__pycache__"
]
line-length = 88
select = ['E', 'F', 'W']
ignore = ["E203"]
# Assume Python 3.7
target-version = "py37"
[per-file-ignores]
# tests often manipulate sys.path before importing the main tools, so ignore import order violations
"test/*.py" = ["E402"]
# multiple spaces after ',' and long lines - used for visual layout of eFuse data
"espefuse/efuse/*/mem_definition.py" = ["E241", "E501"]
"espefuse/efuse/*/operations.py" = ["E241", "E501", "F401"]
"espefuse/efuse/*/fields.py" = ["E241", "E501"]
# ignore long lines - used for RS encoding pairs
"test/test_modules.py" = ["E501"]
# don't check for unused imports in __init__.py files
"__init__.py" = ["F401"]
# allow definition from star imports in docs config
"docs/conf_common.py" = ["F405"]
[lint]
# Enable Pyflakes (`F`) and a subset of the pycodestyle (`E`) codes by default.
# Unlike Flake8, Ruff doesn't enable pycodestyle warnings (`W`) or
# McCabe complexity (`C901`) by default.
select = ["E4", "E7", "E9", "F"]
ignore = []
# Allow fix for all enabled rules (when `--fix`) is provided.
fixable = ["ALL"]
unfixable = []
# Allow unused variables when underscore-prefixed.
dummy-variable-rgx = "^(_+|(_+[a-zA-Z0-9_]*[a-zA-Z0-9]+?))$"
# ruff-format hook configuration
[format]
quote-style = "double"
indent-style = "space"
docstring-code-format = true
Loading...
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化