Using and Mastering Cookiecutter Transcripts
Chapter: Adding features to Cookiecutter
Lecture: Preparing source for the feature

Login or purchase this course to watch this video and the rest of the course contents.
0:01 Now that we have cookiecutter working here,
0:03 you're going to be tempted to want to just start adding your feature,
0:06 get in there and get into that source code, but let's take one step really quick
0:09 so that things are a little simpler for us
0:12 in order to add this feature on a feature branch
0:15 so we can make multiple features, have them all in flight at the same time, things like that.
0:20 So I'm going to switch out of the terminal to my favorite git client which is SourceTree,
0:25 so I'm going to open this directory so I can get hold of it,
0:28 go over here, let's come to source tree, and let's just put cookiecutter right there
0:32 ok that's my cookiecutter on GitHub, notice here you can see
0:39 it's just got all the features from when was the last from what they did, here we go,
0:44 this is the last branch as you can see,
0:48 these are all modified by me on my local version
0:51 this is the last branch in sync with cookiecutter itself.
0:55 When you do this, it'll probably be right at the top,
0:58 so you just want to branch from there, but I'm going to find the latest one
1:01 that's in sync with the official cookiecutter repo
1:05 and I'm going to create a branch because what I want to do is
1:07 do all of the work only for that feature on that one branch, so let's do that.
1:10 So we'll come over here, and we'll say branch,
1:14 now here's a cool trick that you can use
1:17 if you use your name or your user name or basically if you separate with slashes
1:20 you can make a hierarchy of features, so I am going to say this
1:23 I'll say mikeycennedy that's my github name
1:26 and then I'm going to say forgiving YAML fix,
1:30 so forgiving YAML formats not super annoying,
1:34 hey you need a newline there, you forgot that version
1:37 so I'm going to checkout to this particular commit,
1:41 and I'm going to go ahead and check out that new branch
1:44 so I'll start working from there ok
1:47 and notice, with the / here, this will actually create like a little tree of things,
1:50 which is pretty cool, so we're over here
1:53 now notice, when we did that checkout it said
1:56 hey there's this virtual environment here, I don't want that, so what I'm going to do is
1:59 I'm going to say ignore everything under .env,
2:01 if this pull request gets accepted you probably won't have to do this, we'll see
2:05 but we're going to just update the .gitignore to say
2:08 don't check in that virtual environment it's not cross-platform anyway
2:12 so I'll just add that in real quick, ignore virtual env directory, ok,
2:17 so now everything is clean in our feature branch right here,
2:22 if we go over here you can see that we have that one checked out
2:26 we're on the forgiving YAML fix directory
2:28 we're ready to make the code itself
2:31 actually do the code change that makes this forgiving YAML.