-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathpyproject.toml
More file actions
123 lines (106 loc) · 3.33 KB
/
pyproject.toml
File metadata and controls
123 lines (106 loc) · 3.33 KB
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
[project]
name = "vcf-generator-lite"
version = "5.0.2"
description = "Makes one vCard from a contact list."
authors = [{ name = "Jesse205", email = "jesse205@qq.com" }]
license = "Apache-2.0"
license-files = ["LICENSE"]
readme = "README_pypi.md"
requires-python = ">=3.12"
dependencies = ["ttk-text==0.3.3"]
import-names = ["vcf_generator_lite"]
[project.optional-dependencies]
console = ["colorlog>=6.9.0"]
[dependency-groups]
basic = ["poethepoet>=0.42.1"]
test = ["pytest>=9.0.2"]
lint = ["pyright>=1.1.407", "ruff>=0.14.10"]
build = ["packaging>=26.0", "pyinstaller>=6.17.0", "requests>=2.32.5"]
dev = ["colorlog>=6.9.0"]
[project.urls]
Repository = "https://gitee.com/hellotool/VCFGeneratorLiteWithTkinter"
Github = "https://github.com/hellotool/VCFGeneratorLiteWithTkinter"
Issues = "https://gitee.com/hellotool/VCFGeneratorLiteWithTkinter/issues/new/choose"
[project.gui-scripts]
vcf-generator-lite = "vcf_generator_lite.__main__:main"
[build-system]
requires = ["uv_build>=0.11.3,<0.12"]
build-backend = "uv_build"
[tool.poe]
executor = "uv"
[tool.poe.tasks]
test = "pytest"
lint = "ruff check"
format = "ruff format"
build-installer.script = "scripts.build_app:build_installer"
build-portable.script = "scripts.build_app:build_portable"
build-zipapp.script = "scripts.build_app:build_zipapp"
build-wheel = "uv build --wheel"
[tool.uv]
required-version = ">=0.10.1"
default-groups = "all"
[tool.uv.pip]
universal = true
[tool.ruff]
line-length = 120
extend-exclude = ["typings/**"]
[tool.ruff.lint]
ignore = [
"D100", # 有时候文档不是必须的
"D101",
"D102",
"D103",
"D104",
"D107",
"D400", # 不支持中文标点
"PLC0415", # 为了防止兼容性问题或者不必要的代码运行,需要将导入放到函数内。
"FBT001", # 在设置单个值时不需要命名参数
"FBT003",
"ICN001", # 很多情况下简写语义不明,要尽量避免简写
"T201", # 有 CLI 需求
"PLR0913", # 参数多不是问题,问题是参数多且没使用命名参数
"PLR2004", # 有时候,一些长度判断、常见状态码不需要常量
"S113", # 万一就是要等很长时间
"ANN003", # 无法做到
"ANN201", # 为了保持简洁,None 类型不写返回类型
"ANN202",
"ANN204",
"COM812", # 可能与 Formatter 冲突
"TRY003", # 没有必要
"EM101",
"EM102",
]
select = ["ALL"]
exclude = ["tests/**"]
allowed-confusables = [",", ":", "(", ")", ";"] # 允许中文符号
[tool.ruff.lint.pydocstyle]
convention = "pep257"
[tool.ruff.format]
docstring-code-format = true
line-ending = "lf"
[tool.pyright]
strictListInference = true
strictDictionaryInference = true
strictSetInference = true
deprecateTypingAliases = true
typeCheckingMode = "strict"
reportUnknownMemberType = "none"
reportUnknownParameterType = "none"
reportUnknownArgumentType = "none"
reportIncompatibleVariableOverride = "none"
reportMissingParameterType = "none"
reportUnknownVariableType = "none"
reportUnnecessaryIsInstance = "none"
reportImplicitOverride = "error"
ignore = ["typings", "build", "dist", ".venv"]
[tool.pytest]
testpaths = ["tests"]
python_files = ["test_*.py"]
python_classes = ["Test*"]
python_functions = ["test_*"]
strict_config = true
strict_markers = true
strict_xfail = true
filterwarnings = ["error", "ignore::DeprecationWarning"]
log_cli = true
log_cli_level = "INFO"