Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit cd24957

Browse filesBrowse files
committed
Add settings for Ruff and run ruff format
1 parent 98961bb commit cd24957
Copy full SHA for cd24957

File tree

Expand file treeCollapse file tree

3 files changed

+1283
-716
lines changed
Filter options
Expand file treeCollapse file tree

3 files changed

+1283
-716
lines changed

‎pyproject.toml

Copy file name to clipboardExpand all lines: pyproject.toml
+66Lines changed: 66 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,72 @@
22
requires = ["setuptools"]
33
build-backend = "setuptools.build_meta"
44

5+
6+
[tool.ruff]
7+
# Exclude a variety of commonly ignored directories.
8+
exclude = [
9+
".bzr",
10+
".direnv",
11+
".eggs",
12+
".git",
13+
".git-rewrite",
14+
".hg",
15+
".ipynb_checkpoints",
16+
".mypy_cache",
17+
".nox",
18+
".pants.d",
19+
".pyenv",
20+
".pytest_cache",
21+
".pytype",
22+
".ruff_cache",
23+
".svn",
24+
".tox",
25+
".venv",
26+
".vscode",
27+
"__pypackages__",
28+
"_build",
29+
"buck-out",
30+
"build",
31+
"dist",
32+
"node_modules",
33+
"site-packages",
34+
"venv",
35+
]
36+
37+
# Same as Black.
38+
line-length = 88
39+
indent-width = 4
40+
41+
# Assume Python 3.9
42+
target-version = "py39"
43+
44+
[tool.ruff.lint]
45+
# Enable Pyflakes (`F`) and a subset of the pycodestyle (`E`) codes by default.
46+
select = ["E4", "E7", "E9", "F"]
47+
ignore = []
48+
49+
# Allow fix for all enabled rules (when `--fix`) is provided.
50+
fixable = ["ALL"]
51+
unfixable = []
52+
53+
# Allow unused variables when underscore-prefixed.
54+
dummy-variable-rgx = "^(_+|(_+[a-zA-Z0-9_]*[a-zA-Z0-9]+?))$"
55+
56+
[tool.ruff.format]
57+
# Like Black, use double quotes for strings.
58+
quote-style = "double"
59+
60+
# Like Black, indent with spaces, rather than tabs.
61+
indent-style = "space"
62+
63+
# Like Black, respect magic trailing commas.
64+
skip-magic-trailing-comma = false
65+
66+
# Like Black, automatically detect the appropriate line ending.
67+
line-ending = "auto"
68+
69+
70+
571
[tool.pylint.MASTER]
672
load-plugins=[
773
"pylint_per_file_ignores",

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.