Using and Mastering Cookiecutter Transcripts
Chapter: Welcome to the course
Lecture: Welcome and what is Cookiecutter

Login or purchase this course to watch this video and the rest of the course contents.
0:01 Hello and welcome to "Using and Mastering Cookiecutter".
0:06 I'm really excited that you are taking this course
0:09 and that you are interested into looking into Cookiecutter.
0:12 It's a fantastic tool and it's really powerful,
0:15 I think you are going to learn and appreciate a lot of that power, in this course.
0:20 Let's begin by answering the question what is Cookiecutter?
0:23 Well, we can create a template, a set of files for any given project,
0:27 this could be a Python application, this could be an Apple application,
0:31 this could even just be some scientific research project template
0:35 that doesn't have any code at all, we're going to create this template
0:39 and we're going to feed it to the Cookiecutter engine.
0:42 Now, this could be Python, it could be C++, it could be C#,
0:48 the language of the template is irrelevant, it's about managing files
0:51 and resources and creating project structure from some source template
0:56 and asking the user a certain number of questions,
0:59 so things like what is your project called,
1:02 are you going to deploy this to the cloud,
1:05 what ORM are you going to use and so on.
1:07 So we are going to take the template and feed this information into Cookiecutter
1:10 and out pops a brand new shiny, ready to start project.
1:13 So that is what Cookiecutter is.
1:16 It takes templates called Cookiecutters,
1:19 and it generates via asking the users a couple of questions,
1:22 project templates for any type of app that you want to get started with.
1:26 Cookiecutter was created by Audrey Roy Greenfeld, back in 2013,
1:32 you may know Audrey from the Two Scoops of Django,
1:35 she and her husband Danny wrote this book and it's very well known Django book,
1:39 you can read Danny's announcement of the Cookiecutter project here at this url,
1:44 when they first launched it, it will give you a little background information
1:48 on what Cookiecutter is and why they created it.
1:51 So, when and how do you use Cookiecutter?
1:53 I think there is two cases, on one hand you might just be
1:56 a user who wants to just consume Cookiecutter templates,
2:00 I want to create a new Django project that is set up
2:02 just so based on a Cookiecutter template,
2:05 I want to create a new Pyramid web app based on a Cookiecutter template.
2:09 So, for these types of users, there is certain benefits,
2:13 first of all, you can easily create very complex and intricate projects,
2:17 the Cookiecutter can be set up to create the project however it needs to be done,
2:21 and all you have to do is answer a few basic questions,
2:24 and instead of worrying about what files you have to create,
2:27 how they are relatively located to each other, things like that, the formats,
2:30 you just answer a few questions and boom, you have some new app ready to roll.
2:34 It makes the process of creating projects very repeatable, and that is nice.
2:39 It also is faster onboarding for new developers,
2:42 so instead of teaching developers all the things you need to know
2:45 about the layout and structure of a project, you can just say run this command,
2:49 Cookiecutter (space) my template name, and boom, they are ready to go.
2:53 On the other hand, you might want to create Cookiecutter template,
2:57 maybe you work at a company and you want to create
3:00 a Cookiecutter template for your team or your organization,
3:02 or you might run an open source project where you want to create
3:05 a template for users of that open source project.
3:08 So here you can possibly increase adoption of your project,
3:11 maybe it was something that was kind of hard to get started with,
3:14 and now because you have a simple template to do so,
3:17 it's easy, you can reduce support costs or support effort right,
3:22 you won't have to answer those, well, how do I get started,
3:24 how do I do this thing, or how do I set up that to get this thing to run,
3:28 your Cookiecutter template will get them beyond the initial setup steps
3:31 so you basically can skip a bunch of those questions and challenges.
3:35 You can help users fall into the pit of success,
3:39 by that I mean you can setup your project, so that everything is set up
3:43 in the best possible way before they even start to touch it,
3:46 and give them the guidance to get going,
3:48 not just creating the file structure and so on,
3:50 but actually asking them the right questions.
3:53 And as you will see in the programmatic part,
3:56 you can even wrap this up in a little application,
3:58 that makes this process of creation even nicer.
4:01 And, you could gain more exposure for your project,
4:03 if it's an open source project, you could get that project listed
4:06 in the Cookiecutter documentation saying here is a way to create this cool project,
4:10 people might look at that and go oh, I didn't know that existed,
4:13 let me check that out, and of course, it will be easy for them to do so,
4:16 because they just have to run your template.
4:18 Finally, if you work inside a company, this can provide
4:21 a lot of consistency across your organization.
4:24 If the way all new projects that your company created is
4:27 by running a certain Cookiecutter template for your technology,
4:30 then you can be sure that there is a minimum level of consistency
4:34 across all those projects and if you have a lot of projects,
4:37 a lot of developers all working in parallel, this can be super valuable
4:40 if you invest into these templates.
4:43 So, this is just some of the use cases
4:46 and some of the reasons that you might use Cookiecutter.
4:48 We'll talk about a whole bunch more as you go through this course.