Using and Mastering Cookiecutter Transcripts
Chapter: Creating Cookiecutter templates
Lecture: Shipping files without processing them

Login or purchase this course to watch this video and the rest of the course contents.
0:01 Let's imagine you want to create a template that will generate projects and those projects themselves need to be able to run a Cookiecutter template.
0:12 Well that can pose a real problem because anything in this entire directory structure is going to be renamed and modified and so on, but as you know,
0:20 we probably want our Cookiecutter to have {{cookiecutter.project_name}} for its directory and it's going to have its own cookiecutter.json
0:28 and its own replacements in its files, and so on, so if you want to ship Jinja content that you want to be not modified,
0:35 as part of this template generation process, you can do it and it's pretty easy. So if your project especially ships with a Cookiecutter template
0:45 that is supposed to arrive in Cookiecutter template form, not process, you're going to need to take this step.
0:52 So we can come over here to our projects, and you've seen the prompt bits, but the new things is we can now add copy without render,
0:59 and we can apply this to a couple of things, we can say anything under the static folder, these are like big files and so on, just leave them alone,
1:06 there is maybe hundreds of files, maybe our project will generate its template quicker
1:12 if we just say stay out of static, there is nothing in here for you to do, we can also say don't mess with cookiecutter.json now to be clear,
1:18 this is not this file, this is the file inside the project, a little bit further down. This is the file within your template and finally,
1:25 you can also say if there is a directory called {{cookiecutter.project_slug}} well, leave that alone as well
1:34 because that is the top level to your template maybe.


Talk Python's Mastodon Michael Kennedy's Mastodon