-
Notifications
You must be signed in to change notification settings - Fork 2
/
pyproject.toml
63 lines (53 loc) · 1.99 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
[project]
name = "python-template"
version = "0.1.0"
description = "Add your description here"
authors = [{ name = "sushi-chaaaan", email = "[email protected]" }]
dependencies = []
readme = "README.md"
requires-python = ">= 3.11"
[build-system]
requires = ["hatchling"]
build-backend = "hatchling.build"
[tool.rye]
managed = true
virtual = true
dev-dependencies = ["ruff>=0.5.0"]
[tool.ruff]
# https://qiita.com/yuji38kwmt/items/63e82126076204923520
target-version = "py311"
line-length = 125
[tool.ruff.lint]
ignore = [
"E203",
"D",
"RUF001", # 全角記号など`ambiguous unicode character`も使いたいため
"RUF002", # 全角記号など`ambiguous unicode character`も使いたいため
"RUF003", # 全角記号など`ambiguous unicode character`も使いたいため
"PLC1901", # compare-to-empty-string : `if a == "`のように空文字列で直接比較したいときがあるため
"ANN101", # missing-type-self: 引数selfには型ヒントは付けていないため
"ANN102", # missing-type-cls: 引数clsには型ヒントは付けていないため
"ERA", # : 役立つこともあるが、コメントアウトしていないコードも警告されるので無視する
"COM812", # recommended by ruff formatter
"ISC001", # recommended by ruff formatter
"UP040", # discord.py can not understand new type syntax
"INP001", # add __init__.py to tests directory is too much work
]
select = ["ALL"]
[tool.ruff.lint.per-file-ignores]
"/**/tests/**" = [
"S101", # allow to use assert in tests
]
[tool.ruff.format]
# Like Black, use double quotes for strings.
quote-style = "double"
# Like Black, indent with spaces, rather than tabs.
indent-style = "space"
# Like Black, respect magic trailing commas.
skip-magic-trailing-comma = false
# Like Black, automatically detect the appropriate line ending.
line-ending = "auto"
[tool.hatch.metadata]
allow-direct-references = true
[tool.hatch.build.targets.wheel]
packages = ["src/python_template"]