diff --git a/tests/fixtures/mkdocs/pattern.json b/tests/fixtures/mkdocs/pattern.json new file mode 100644 index 0000000..e634d1d --- /dev/null +++ b/tests/fixtures/mkdocs/pattern.json @@ -0,0 +1,54 @@ +{ + "template_location": "{{ repo_name }}", + "copy_only": [ + "overrides/**/*", + "overrides/**/.*" + ], + "questions": [ + { + "name": "project_name", + "prompt": "What is the human-friendly name of the project?", + "type": "str", + "default": "My Project" + }, + { + "name": "package_name", + "prompt": "What is the name of the Python package?", + "type": "str", + "default": "{{ project_name|lower|replace(' ', '_') }}" + }, + { + "name": "repo_name", + "prompt": "What is the name of the project repository?", + "type": "str", + "default": "{{ package_name|replace('_', '-') }}" + }, + { + "name": "project_description", + "help": "A sentence or two about what this project does.", + "type": "str", + "default": "" + } + ], + "extra_context": { + "requirements": { + "docs": [ + "black", + "markdown-customblocks", + "mdx-truly-sane-lists", + "mkdocs", + "mkdocs-click", + "mkdocs-gen-files", + "mkdocs-git-authors-plugin", + "mkdocs-git-committers-plugin", + "mkdocs-git-revision-date-localized-plugin", + "mkdocs-include-markdown-plugin", + "mkdocs-literate-nav", + "mkdocs-material", + "mkdocs-section-index", + "mkdocstrings[python]", + "python-frontmatter" + ] + } + } +} diff --git a/tests/fixtures/mkdocs/pattern.yaml b/tests/fixtures/mkdocs/pattern.yaml new file mode 100644 index 0000000..84221b9 --- /dev/null +++ b/tests/fixtures/mkdocs/pattern.yaml @@ -0,0 +1,39 @@ +copy_only: +- overrides/**/* +- overrides/**/.* +extra_context: + requirements: + docs: + - black + - markdown-customblocks + - mdx-truly-sane-lists + - mkdocs + - mkdocs-click + - mkdocs-gen-files + - mkdocs-git-authors-plugin + - mkdocs-git-committers-plugin + - mkdocs-git-revision-date-localized-plugin + - mkdocs-include-markdown-plugin + - mkdocs-literate-nav + - mkdocs-material + - mkdocs-section-index + - mkdocstrings[python] + - python-frontmatter +questions: +- default: My Project + name: project_name + prompt: What is the human-friendly name of the project? + type: str +- default: '{{ project_name|lower|replace('' '', ''_'') }}' + name: package_name + prompt: What is the name of the Python package? + type: str +- default: '{{ package_name|replace(''_'', ''-'') }}' + name: repo_name + prompt: What is the name of the project repository? + type: str +- default: '' + help: A sentence or two about what this project does. + name: project_description + type: str +template_location: '{{ repo_name }}' diff --git a/tests/fixtures/python-boilerplate/pattern.json b/tests/fixtures/python-boilerplate/pattern.json new file mode 100644 index 0000000..42327a0 --- /dev/null +++ b/tests/fixtures/python-boilerplate/pattern.json @@ -0,0 +1,78 @@ +{ + "template_location": "{{ repo_name }}", + "copy_only": [ + ".github/**/*.jinja", + ".github/workflows/*", + ".github/actions/*" + ], + "questions": [ + { + "name": "project_name", + "prompt": "What is the human-friendly name of the project?", + "type": "str", + "default": "My Project" + }, + { + "name": "package_name", + "promp": "What is the name of the Python package?", + "type": "str", + "default": "{{ project_name|lower|replace(' ', '_') }}" + }, + { + "name": "repo_name", + "prompt": "What is the name of the project repository?", + "type": "str", + "default": "{{ package_name|replace('_', '-') }}" + }, + { + "name": "project_description", + "help": "A sentence or two about what this project does.", + "type": "str", + "default": "" + }, + { + "name": "initial_version", + "prompt": "What should the initial version be?", + "type": "str", + "default": "0.1.0" + }, + { + "name": "author", + "prompt": "What is the author's name?", + "default": "Who am I?", + "type": "str" + }, + { + "name": "email", + "prompt": "What is the author's email address?", + "default": "whoami@existential-crisis.doom", + "type": "str" + }, + { + "name": "github_user", + "prompt": "What is the GitHub user name or organization?", + "default": "whoami", + "type": "str" + } + ], + "extra_context": { + "requirements": [ + { + "prod": [ + "environs" + ], + "test": [ + "coverage", + "pre-commit", + "pytest-cov", + "pytest" + ], + "dev": [ + "bump-my-version", + "generate-changelog", + "uv" + ] + } + ] + } +} diff --git a/tests/fixtures/python-boilerplate/pattern.yaml b/tests/fixtures/python-boilerplate/pattern.yaml new file mode 100644 index 0000000..c19401b --- /dev/null +++ b/tests/fixtures/python-boilerplate/pattern.yaml @@ -0,0 +1,51 @@ +copy_only: +- .github/**/*.jinja +- .github/workflows/* +- .github/actions/* +extra_context: + requirements: + - dev: + - bump-my-version + - generate-changelog + - uv + prod: + - environs + test: + - coverage + - pre-commit + - pytest-cov + - pytest +questions: +- default: My Project + name: project_name + prompt: What is the human-friendly name of the project? + type: str +- default: '{{ project_name|lower|replace('' '', ''_'') }}' + name: package_name + promp: What is the name of the Python package? + type: str +- default: '{{ package_name|replace(''_'', ''-'') }}' + name: repo_name + prompt: What is the name of the project repository? + type: str +- default: '' + help: A sentence or two about what this project does. + name: project_description + type: str +- default: 0.1.0 + name: initial_version + prompt: What should the initial version be? + type: str +- default: Who am I? + name: author + prompt: What is the author's name? + type: str +- default: whoami@existential-crisis.doom + name: email + prompt: What is the author's email address? + type: str +- default: whoami + name: github_user + prompt: What is the GitHub user name or organization? + type: str +template_location: '{{ repo_name }}' diff --git a/tests/fixtures/python-package/pattern.json b/tests/fixtures/python-package/pattern.json new file mode 100644 index 0000000..c5d236c --- /dev/null +++ b/tests/fixtures/python-package/pattern.json @@ -0,0 +1,41 @@ +{ + "template_location": "{{ repo_name }}", + "questions": [ + { + "name": "project_name", + "prompt": "What is the human-friendly name of the project?", + "type": "str", + "default": "My Project" + }, + { + "name": "package_name", + "promp": "What is the name of the Python package?", + "type": "str", + "default": "{{ project_name|lower|replace(' ', '_') }}" + }, + { + "name": "repo_name", + "prompt": "What is the name of the project repository?", + "type": "str", + "default": "{{ package_name|replace('_', '-') }}" + }, + { + "name": "project_description", + "help": "A sentence or two about what this project does.", + "type": "str", + "default": "" + }, + { + "name": "initial_version", + "prompt": "What should the initial version be?", + "type": "str", + "default": "0.1.0" + }, + { + "name": "author", + "prompt": "What is the author's name?", + "default": "Who am I?", + "type": "str" + } + ] +} diff --git a/tests/fixtures/python-package/pattern.yaml b/tests/fixtures/python-package/pattern.yaml new file mode 100644 index 0000000..fd2fc1f --- /dev/null +++ b/tests/fixtures/python-package/pattern.yaml @@ -0,0 +1,26 @@ +questions: +- default: My Project + name: project_name + prompt: What is the human-friendly name of the project? + type: str +- default: '{{ project_name|lower|replace('' '', ''_'') }}' + name: package_name + promp: What is the name of the Python package? + type: str +- default: '{{ package_name|replace(''_'', ''-'') }}' + name: repo_name + prompt: What is the name of the project repository? + type: str +- default: '' + help: A sentence or two about what this project does. + name: project_description + type: str +- default: 0.1.0 + name: initial_version + prompt: What should the initial version be? + type: str +- default: Who am I? + name: author + prompt: What is the author's name? + type: str +template_location: '{{ repo_name }}'