-
Notifications
You must be signed in to change notification settings - Fork 0
/
pyproject.toml
127 lines (108 loc) · 2.35 KB
/
pyproject.toml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
[build-system]
requires = [
"poetry-core>=1.0.0",
"poetry-dynamic-versioning>=1.0.0,<2.0.0",
]
build-backend = "poetry_dynamic_versioning.backend"
[tool.coverage.report]
show_missing = true
omit = [
"*/usr/local/lib*",
"*/lib/python*/*",
"lib/*",
"src/*",
"tests/*",
]
[tool.coverage.run]
branch = true
command_line = "-m pytest"
omit = [
"*/usr/local/lib*",
"*/lib/python*/*",
"lib/*",
"src/*",
"tests/*",
]
[tool.flake8]
per-file-ignores = """
tests: S101
"""
[tool.poe.tasks.coverage]
shell = """
poetry run coverage run \
&& poetry run coverage html \
&& open htmlcov/index.html
"""
[tool.poetry]
name = "pysimplecli"
version = "0.0.0" # Placeholder
description = "Easily turn functions into command line utilities"
authors = ["Clif Bratcher <[email protected]>"]
readme = "README.md"
packages = [
{include = "simplecli"}
]
[tool.poetry.dependencies]
python = "^3.9"
[tool.poetry.group.test.dependencies]
pytest ="*"
typing_extensions = "*"
[tool.poetry.group.dev.dependencies]
bandit = "^1.7.8"
coverage = "^7.4.4"
flake8 = "^7.0.0"
poethepoet = "*"
ruff = "^0.3.4"
[tool.poetry-dynamic-versioning]
enable = true
vcs = "git"
[tool.pytest.ini_options]
testpaths = [
"tests",
]
[tool.ruff]
line-length = 79
indent-width = 4
# output-format = "github"
[tool.ruff.format]
quote-style = "double"
indent-style = "space"
skip-magic-trailing-comma = false
exclude = [
"tests/test_extract_args.py",
]
[tool.ruff.lint]
preview = true
explicit-preview-rules = true
dummy-variable-rgx = "^(_+|(_+[a-zA-Z0-9_]*[a-zA-Z0-9]+?))$"
select = [
"ANN", # flake8-annotations
"B", # flake8-bugbear
"C90", # mccabe (code complexity)
"E", # pycodestyle
"F", # Pyflakes
"RET", # flake8-return
"SIM", # flake8-simplify
"S", # flake8-bandit
"UP", # pyupgrade
"E203",
]
ignore = [
"ANN101", # No need to annotate 'self'
"UP007", # Do not recomment translating Union to X | Y
"SIM102", # Allow nested `if` for ease of reading
"RET505", # Don't force `if` when `elif` follows a return
"S101", # Use of `assert` detected
]
[tool.ruff.lint.per-file-ignores]
"tests/*" = [
"ANN001",
"ANN201",
"ANN202",
]
[tool.ruff.lint.isort]
no-sections = true
[tool.ruff.lint.mccabe]
max-complexity = 9
[tool.ruff.lint.flake8-annotations]
allow-star-arg-any = true