-
Notifications
You must be signed in to change notification settings - Fork 0
/
copier.yml
97 lines (85 loc) · 2.21 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
_envops:
trim_blocks: true
_subdirectory: "template"
project_name:
help: "Project name"
type: "str"
placeholder: "Lorem Ipsum"
validator: >
{%- if not project_name -%}
You must provide a project name.
{%- endif -%}
project_slug:
when: false
default: "{{ project_name | lower | replace(' ', '-') | replace('_', '-') }}"
project_description:
help: "Project description"
type: "str"
placeholder: "Lorem ipsum dolor sit amet."
validator: >
{%- if not project_description -%}
You must provide a project description.
{%- elif project_description[-1] not in ".!?…" -%}
The project description must end with a punctuation mark.
{%- endif -%}
author_name:
help: "Your full name"
type: "str"
placeholder: "John Doe"
validator: >
{%- if not author_name -%}
You must provide your full name.
{%- endif -%}
license:
help: "Project license"
type: "str"
choices:
- "MIT"
- "Proprietary"
default: "Proprietary"
copyright_holder:
help: "Name of the person or entity holding the copyright"
type: "str"
default: "{{ author_name }}"
validator: >
{%- if not copyright_holder -%}
You must provide a copyright holder.
{%- endif -%}
copyright_year:
help: "Copyright year"
type: "int"
default: 2024
validator: >
{%- if not 2020 <= copyright_year <= 2100 -%}
You must provide a valid year between 2020 and 2100.
{%- endif -%}
hosting_platform:
help: "Code hosting platform for the project"
type: "str"
choices:
- "none"
- "github"
github_account:
when: "{{ hosting_platform == 'github' }}"
help: "GitHub account (username or organization)"
type: "str"
placeholder: "jdoe"
validator: >
{%- if not github_account -%}
You must provide a GitHub account.
{%- endif -%}
repo_name:
when: "{{ hosting_platform != 'none' }}"
help: "Name of the{% if hosting_platform == 'github' %} GitHub{% endif %} repository"
type: "str"
default: "copier-{{ project_slug }}"
validator: >
{%- if not repo_name -%}
You must provide a repository name.
{%- endif -%}
repo_url:
when: false
default: >
{%- if hosting_platform == 'github' -%}
https://github.com/{{ github_account }}/{{ repo_name }}
{%- endif -%}