documentation
documentation copied to clipboard
[Bug]: The templates documentation does not reflect what's happening during templates:generate command
Link to the documentation page or resource
https://docs.strapi.io/developer-docs/latest/setup-deployment-guides/installation/templates.html
Describe the bug
There are several discrepancies with the templates documentation and what the templates:generate
command is actually doing.
When I run yarn strapi templates:generate blog
, the folder structure generated is not what is specified in the list of "allowed" files.

I end up with:

Notice admin
, src
are not listed in the docs as being allowed files.
Also, after pushing to github and running the command
npx create-strapi-app blog001 --template https://github.com/rawestmoreland/strapi-template-blog
I get the error:
Error: ⛔️ Template installation failed: Command failed: npm view https://github.com/rawestmoreland/strapi-template-blog name version --silent
at createProject (/Users/richard/.config/yarn/global/node_modules/@strapi/generate-new/lib/create-project.js:82:15)
at processTicksAndRejections (internal/process/task_queues.js:95:5)
at async createQuickStartProject (/Users/richard/.config/yarn/global/node_modules/@strapi/generate-new/lib/create-quickstart-project.js:23:3)
I had attempted the above command with both node 16 and node 14. Both yarn
and npx
Additional context
To repro:
- Create a strapi project with the strapi/blog template.
- Create a template from that with
yarn strapi templates:generate blog
- Push to repo
- Run
yarn create strapi-app blog001 --template <github-template-url>
- Notice the errors
Suggested improvements or fixes
I think the documentation is perhaps old and pertains to strapi v3.
What is the proper way to create a template and then use that template after pushing to github?
Related issue(s)/PR(s)
No response
Talked with the user on Discord and confirmed the docs are quite out of date here. We will need to talk to the expansion squad to update these.
Thank you for opening this issue @rawestmoreland and for opening a PR as well! 🤗 As you know, our devs are also updating the documentation (see PR #665 ). We'll keep you updated :-)