Skip to content

Commit 08a9f37

Browse files
committed
Updated hooks/post_gen_project.py
Added a task to install python and updated venv creation to use cookiecutter.python_version_dev.
1 parent e9681a7 commit 08a9f37

File tree

1 file changed

+10
-1
lines changed

1 file changed

+10
-1
lines changed

hooks/post_gen_project.py

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,16 @@ def __call__(self, *, verbose: bool = True) -> str:
5757
def post_generation_tasks() -> int:
5858
"""Things to do after cookiecutter has rendered the template."""
5959
tasks = [
60-
Task("Create .venv", "uv --verbose venv", required=True),
60+
Task(
61+
"Install Dev Python",
62+
"uv python install {{ cookiecutter.python_version_dev }}",
63+
required=True,
64+
),
65+
Task(
66+
"Create .venv",
67+
"uv --verbose venv --python {{ cookiecutter.python_version_dev }} --managed-python",
68+
required=True,
69+
),
6170
Task("Enable Direnv", "direnv allow", required=False),
6271
Task("Sync Project Deps", "uv --quiet --no-progress sync", required=True),
6372
Task("Initialize Git", "git init --quiet --initial-branch main", required=True),

0 commit comments

Comments
 (0)