Skip to content

Commit 0e4d01b

Browse files
committed
fix: replace old loop with jinja plus assignment separate
1 parent b0ba18a commit 0e4d01b

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

hooks/pre_gen_project.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,10 +4,11 @@
44
ESCAPED_JINJA_SETUP: str = """
55
{%- set min_minor = cookiecutter.min_python_version.split('.')[1] | int %}
66
{%- set max_minor = cookiecutter.max_python_version.split('.')[1] | int %}
7+
{%- set versions = ["3." + (i|string) for i in range(min_minor, max_minor + 1)] %}
78
89
{{ cookiecutter.update({
910
"_min_python_version_minor_int": min_minor,
1011
"_max_python_version_minor_int": max_minor,
11-
"python_versions": ["3.10", "3.11", "3.12", "3.13", "3.14"]
12+
"python_versions": versions
1213
}) }}
1314
"""

0 commit comments

Comments
 (0)