Skip to content

feat: convert repository to cookiecutter template#14

Merged
h0pers merged 4 commits into
masterfrom
feature/cookiecutter-template
Jun 30, 2026
Merged

feat: convert repository to cookiecutter template#14
h0pers merged 4 commits into
masterfrom
feature/cookiecutter-template

Conversation

@h0pers

@h0pers h0pers commented Jun 30, 2026

Copy link
Copy Markdown
Owner

Summary

  • Restructure repository as a Cookiecutter template with use_drf option
  • Add Jinja2 conditionals for optional DRF, drf-spectacular, and django-cors-headers
  • Add post-generation hook to remove DRF-only files when use_drf=n
  • Add template validation CI workflow that tests both option paths

Test plan

  • Run cookiecutter . --no-input and verify DRF + Swagger included
  • Run cookiecutter . --no-input use_drf=n and verify no DRF traces
  • ruff check and ruff format --check pass on both outputs
  • Docker build succeeds for both variants
  • Template validation CI workflow passes

h0pers added 4 commits June 30, 2026 12:10
Add cookiecutter.json, post-generation hook, Jinja2 conditionals
for optional DRF support, and template validation CI workflow.
Ruff fails when run from the repo root because the template's
pyproject.toml contains Jinja2 syntax that is not valid TOML.
pre-commit uses git to discover files and walks up to the parent
repo, which includes the template's invalid pyproject.toml.
@h0pers
h0pers merged commit ce71a1b into master Jun 30, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant