EuroPython 2015

Come to the Dark Side! We have a whole bunch of Cookiecutters!

(This talk is intended for intermediate-level participants who have a basic understanding of the Python language and contains quotes from Darth Vader that some attendees may find hilarious)

Writing a Python script from scratch is fairly easy and you get on with very little boilerplate code in general. However starting a new Python project can be tiring if you decide to stick to best practices and plan on submitting it to PyPI. It requires great diligence and occasionally gets pretty cumbersome if you start new tools on a regular basis.

You underestimate the power of a good template

Why not just use a template for it? Cookiecutter is a CLI tool written in pure Python that enables you to do so. Not only is it working for Python code, but also markdown formats and even other programming languages. We will talk about the ideas behind Cookiecutter and go over how you can create your very own template, so you and others can benefit from your experience.

I would like to briefly go into the technologies used and how you can get involved in the Cookiecutter GitHub project. There are already plenty of Cookiecutter templates, or Cookiecutters as we call them, available online. Most of them target Python projects, but others can be used to create C++, LaTeX or Javascript projects.

The ability to destroy a planet is insignificant next to the power of Cookiecutter.

I will show you how to use Cookiecutter and highlight some of the amazing templates created by the community. More importantly we will create a Cookiecutter template from scratch using the example of a simple Kivy app and make use of advanced features such as post-gen hooks, copy-without-render and templates in context values.

Finally I will recommend resources on how to follow up on this talk and how to get in touch in case of any queries.




in on Thursday 23 July at 11:45 See schedule


Do you have some questions on this talk?

New comment