-
Notifications
You must be signed in to change notification settings - Fork 0
/
pyproject.toml
154 lines (137 loc) · 3.32 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
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
# Copyright (C) 2023 Maxwell G <[email protected]>
# SPDX-License-Identifier: MIT
[build-system]
requires = ["flit_core >=3.2,<4"]
build-backend = "flit_core.buildapi"
[project]
name = "tomcli"
dynamic = ["version"]
description = 'CLI for working with TOML files. Pronounced "tom clee."'
readme = "README.md"
requires-python = ">=3.9"
license.text = "MIT"
authors = [
{ name = "Maxwell G", email = "[email protected]" },
]
classifiers = [
"Development Status :: 3 - Alpha",
"Environment :: Console",
"Programming Language :: Python",
"Programming Language :: Python :: 3.9",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.11",
"Programming Language :: Python :: 3.12",
"Programming Language :: Python :: 3.13",
"Typing :: Typed",
]
dependencies = [
"click",
"importlib_metadata; python_version<'3.11'",
]
[project.optional-dependencies]
# User facing
all = [
# Keep in sync with tomlkit extra.
# We can't use self-referntial extras in Fedora.
"tomlkit",
#
]
tomli = [
"tomli ; python_version<'3.11'",
"tomli_w",
]
tomlkit = [
"tomlkit",
]
# Development
codeqa = [
"ruff >= 0.3.0",
"reuse",
]
formatters = [
"black>=24",
"isort",
]
typing = [
"basedpyright",
"tomcli[tomli]",
"tomcli[tomlkit]",
"mkdocs-gen-files",
"mypy",
"pytest",
# Always install tomli
"tomli",
"typing_extensions",
# For checking noxfile.py
"nox",
"releaserr",
]
test = [
"pytest",
]
dev = [
"tomcli[all]",
"tomcli[codeqa]",
"tomcli[formatters]",
"tomcli[test]",
"tomcli[typing]",
"nox",
]
[project.urls]
Homepage = "https://tomcli.gtmx.me"
Documentation = "https://tomcli.gtmx.me"
Source = "https://git.sr.ht/~gotmax23/tomcli"
"Mailing List" = "https://lists.sr.ht/~gotmax23/tomcli"
Changelog = "https://tomcli.gtmx.me/news/"
[project.scripts]
"tomcli" = "tomcli.cli.main:APP"
"tomcli-get" = "tomcli.cli.get:app"
"tomcli-set" = "tomcli.cli.set:app"
"tomcli-formatters" = "tomcli.cli.formatters:APP"
[project.entry-points."tomcli.formatters"]
default = "tomcli.formatters.builtin:default_formatter"
json = "tomcli.formatters.builtin:json_formatter"
newline-keys = "tomcli.formatters.builtin:newline_keys_formatter"
newline-list = "tomcli.formatters.builtin:newline_list_formatter"
newline-values = "tomcli.formatters.builtin:newline_values_formatter"
string = "tomcli.formatters.builtin:string_formatter"
toml = "tomcli.formatters.builtin:toml_formatter"
[tool.pytest.ini_options]
addopts = [
"--import-mode=importlib",
]
[tool.isort]
profile = "black"
[tool.mypy]
check_untyped_defs = true
[tool.coverage.run]
omit = [
"tests/*.py",
"src/tomcli/_peekable.py",
]
[tool.coverage.paths]
source = [
"src",
"*/site-packages",
]
[tool.coverage.report]
# https://coverage.readthedocs.io/en/latest/excluding.html#advanced-exclusion
# These should use single quotes in TOML, as they're regular expressions.
exclude_lines = [
'pragma: no cover',
'raise NotImplementedError',
'if __name__ == .__main__.:',
'if TYPE_CHECKING:',
'if t\.TYPE_CHECKING:',
'@(abc\.)?abstractmethod',
'@overload',
'except ImportError:',
]
[tool.basedpyright]
typeCheckingMode = "strict"
reportPrivateUsage = false
ignore = [
"src/tomcli/_peekable.py",
# I don't care about strict typing for tests.
"tests",
]