@@ -7,7 +7,11 @@ build-backend = "setuptools.build_meta"
7
7
8
8
[project ]
9
9
name = " {{ cookiecutter.git_repo_name }}"
10
+ {% if cookiecutter.package_manager == 'pip' %}
10
11
dynamic = [" version" , " readme" , " dependencies" ]
12
+ {% elif cookiecutter.package_manager == 'uv' %}
13
+ dynamic = [" version" , " readme" ]
14
+ {% endif %}
11
15
requires-python = " >={{ cookiecutter.minimum_python_version }}"
12
16
description = " {{ cookiecutter.app_description }}"
13
17
keywords = [
@@ -49,6 +53,31 @@ classifiers = [
49
53
50
54
]
51
55
56
+ {% if cookiecutter.package_manager == 'uv' %}
57
+ dependencies = [
58
+ " fastapi" ,
59
+ " pydantic" ,
60
+ " uvicorn" ,
61
+ {% if cookiecutter.use_requests == 'y' %}"requests",{% endif %}
62
+ {% if cookiecutter.use_cryptography == 'y' %}"cryptography",{% endif %}
63
+ ]
64
+
65
+ [dependency-groups ]
66
+ dev = [
67
+ " black" ,
68
+ " tomli" ,
69
+ " pytest-cov" ,
70
+ " sphinx" ,
71
+ " pylint" ,
72
+ " myst-parser" ,
73
+ " sphinx_rtd_theme" ,
74
+ " sphinxcontrib-mermaid" ,
75
+ " httpx" ,
76
+ " bandit" ,
77
+ {% if cookiecutter.use_requests == 'y' %}"requests-mock",{% endif %}
78
+ ]
79
+ {% endif %}
80
+
52
81
[project .urls ]
53
82
Documentation = " https://{{ cookiecutter.git_repo_name }}.readthedocs.io/en/latest/"
54
83
Source = " {{ cookiecutter.git_url }}"
@@ -72,7 +101,9 @@ zip-safe = false
72
101
[tool .setuptools .dynamic ]
73
102
version = {attr = " {{cookiecutter.__app_name}}.version.__version__" }
74
103
readme = {file = " README.md" , content-type = " text/markdown" }
104
+ {% if cookiecutter.package_manager == 'pip' %}
75
105
dependencies = {file = " requirements.txt" }
106
+ {% endif %}
76
107
77
108
[tool .pytest .ini_options ]
78
109
addopts = " --strict-markers"
@@ -107,3 +138,12 @@ exclude_dirs = [
107
138
" venv" ,
108
139
" docs" ,
109
140
]
141
+
142
+ {% if cookiecutter.package_manager == 'uv' %}
143
+ # UV settings reference https://docs.astral.sh/uv/reference/settings/
144
+
145
+ [tool .uv ]
146
+ keyring-provider = " subprocess"
147
+ native-tls = true
148
+
149
+ {% endif %}
0 commit comments