-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy pathcopier.yml
117 lines (99 loc) · 3.34 KB
/
copier.yml
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
# ---------- CONFIG --------
_subdirectory: project
_skip_if_exists:
- README.md
# Tasks to execute after generating or updating a project.
# _tasks:
# - git init -q --initial-branch=main || true
# - "{{ use_pre_commit }} && pre-commit autoupdate || echo 'please run: pip install pre-commit && pre-commit autoupdate'"
# - git add . &&
# git commit -q -m 'initial commit' &&
# echo 'git repo initialized' || echo 'git init failed'
# ---------- PROMPT --------
# https://copier.readthedocs.io/en/stable/configuring/#questions
mode:
help: "Welcome! Please select a mode:"
type: str
default: tooling
choices:
✨ Fully featured - default tooling: tooling
📦 Simple package - minimal tooling: simple
🙋 Customize - ask me questions: customize
project_name:
help: Name of your project (prefer hyphens to underscores)
default: my-project
validator: >-
{% if not (project_name | regex_search('^[a-zA-Z][a-zA-Z0-9\_\-]+$')) %}
project_name must start with a letter, followed one or more letters, digits, hyphens, or underscores all lowercase.
{% endif %}
module_name:
help: Name of your top level python module (what you will import)
default: "{{ project_name.lower().replace(' ', '_').replace('-', '_') }}"
validator: "{% if not module_name.isidentifier() %}Invalid module name{% endif %}"
author_name:
help: Your full name (used in the project metadata)
default: Your Name
author_email:
help: Your email address (used in the project metadata)
default: [email protected]
validator: "{% if '@' not in author_email or '.' not in author_email %}Invalid Email{% endif %}"
project_short_description:
help: A short description of the package
default: Package description.
project_license:
when: "{{ mode == 'customize' }}"
help: What license would you like to use? (https://choosealicense.com/)
type: str
default: BSD-3-Clause
choices:
BSD-3-Clause: BSD-3-Clause
MIT: MIT
Apache-2.0: Apache-2.0
GNU GPLv3: GPL-3.0
none: none
git_versioning:
when: "{{ mode == 'customize' }}"
type: bool
default: "{{ mode != 'simple' }}"
help: How would you like to control versioning?
choices:
"Hardcoded __version__ attribute": false
"Derive from git tags": true
github_username:
help: |
Your GitHub username/organization name
(If you plan to put your project on GitHub)
default: ""
minimum_python:
when: "{{ mode == 'customize' }}"
help: What is the minimum supported Python version (https://devguide.python.org/versions/)?
type: int
default: 9
choices:
🐍 3.9: 9
🐍 3.10: 10
🐍 3.11: 11
🐍 3.12: 12
🐍 3.13: 13
test_pre_release:
when: "{{ mode == 'customize' }}"
help: |
Would you like to run tests against dependecy pre-releases
on a Github Actions cron job?
type: bool
default: "{{ mode != 'simple' }}"
use_pre_commit:
when: "{{ mode == 'customize' }}"
type: bool
help: Would you like to add a pre-commit configuration (linting, formatting, ...)?
default: "{{ mode != 'simple' }}"
use_ruff:
when: "{{ mode == 'customize' and use_pre_commit }}"
type: bool
help: Add ruff for linting and code formatting?
default: "{{ mode != 'simple' }}"
use_mypy:
when: "{{ mode == 'customize' and use_pre_commit }}"
type: bool
help: Add mypy for static type checking on type hints?
default: "{{ mode != 'simple' }}"