Add support for --template argument to wagtail start. Fix #10423 #10566
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Fixes #10423. This is the "MVP" implementation which makes it possible to pass a
--template
tostartproject
, without any other niceties.Potential improvements once we have a clearer idea of what to do with this:
wagtail
CLI, no single source of truth.wagtail start
command #10423 (comment)). This would need building on top ofstartproject
.extensions
,name
, and otherstartproject
options.startproject
optionsstart
norupdatemodulepaths
[ ] For Python changes: Have you added tests to cover the new/fixed behaviour?No, there are no tests for this code currently.[ ] For front-end changes: Did you test on all of Wagtail’s supported environments?[^2][ ] For new features: Has the documentation been updated accordingly?No, there are no docs for this CLITo test this, make sure
start
still works with the default, and make sure it works with a--template
:wagtail start mysite wagtail start mysite --template=https://github.com/thibaudcolas/wagtail-tutorial-template/archive/main.zip # Potentially compare to: ./wagtail/test/manage.py startproject mysite --template=https://github.com/thibaudcolas/wagtail-tutorial-template/archive/main.zip