-
Notifications
You must be signed in to change notification settings - Fork 8
/
pyproject.toml
60 lines (50 loc) · 1.47 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
[build-system]
requires = ["hatchling", "hatch-vcs"]
build-backend = "hatchling.build"
[project]
name = "ipyniivue"
dynamic = ["version"]
description = "A Jupyter Widget for Niivue based on anywidget."
dependencies = ["anywidget"]
readme = "README.md"
[project.optional-dependencies]
dev = ["watchfiles", "jupyterlab", "ruff", "pytest"]
[tool.hatch.envs.default]
features = ["dev"]
uv = true
# https://github.com/ofek/hatch-vcs
[tool.hatch.version]
source = "vcs"
[tool.hatch.build]
only-packages = true
artifacts = ["src/ipyniivue/static/*"]
[tool.hatch.build.hooks.jupyter-builder]
build-function = "hatch_jupyter_builder.npm_builder"
dependencies = ["hatch-jupyter-builder>=0.5.0"]
[tool.hatch.build.hooks.jupyter-builder.build-kwargs]
npm = "npm"
build_cmd = "build"
[tool.hatch.envs.default.scripts]
lint = ["ruff check . {args:.}", "ruff format . --check --diff {args:.}"]
format = ["ruff format . {args:.}", "ruff check . --fix {args:.}"]
test = ["pytest {args:.}"]
[tool.ruff.lint]
pydocstyle = { convention = "numpy" }
select = [
"E", # style errors
"W", # style warnings
"F", # flakes
"D", # pydocstyle
"D417", # Missing argument descriptions in Docstrings
"I", # isort
"UP", # pyupgrade
"C4", # flake8-comprehensions
"B", # flake8-bugbear
"A001", # flake8-builtins
"RUF", # ruff-specific rules
"TCH", # flake8-type-checking
"TID", # flake8-tidy-imports
]
[tool.ruff.lint.per-file-ignores]
"tests/*.py" = ["D", "S"]
"scripts/*.py" = ["D", "S"]