govcookiecutter
How is the template used?
This template helps to set up standardised project structures, and includes security features using pre-commit hooks. This cookiecutter template also acts as an installable template (python projects only).
It also provides an Agile, centralised, and lightweight analytical quality assurance (AQA) process. Pull or merge request templates are used to nudge users to complete this process. This helps meet HM Government best practice on producing quality analysis, as defined in the Aqua Book.
For reasons why we developed govcookiecutter
, read the blog post, and
watch the live demonstration from March 2021 on version 0.5.3.
Project structure layout
The cookiecutter template generated for each project will follow this folder structure:
.
└── govcookiecutter/
├── {{ cookiecutter.repo_name }}/
│ └── {{ cookiecutter.repo_name.lower().replace(' ', '_').replace('-', '_') }}/
│ ├── example_modules/
│ │ ├── __init__.py
│ │ └── example_module.py
│ ├── __init__.py
│ ├── example_config.yml
│ └── run_pipeline.py
└── ...
Getting started
First, make sure your system meets the requirements.
Optional changes to consider post-project creation
Here are some suggested changes to make before your first commit:
consider using the
cruft
package to integrate futuregovcookiecutter
releasespip install cruft cruft link https://github.com/best-practice-and-impact/govcookiecutter
make sure the
README.md
reflects what you want to do with your projecthave a look inside the
docs/aqa
folder, as you may want to modify some of this analytical quality assurance documentation (AQA), for example the AQA plan(if present) confirm that the pull or merge request template checklists meet your requirements
These can be found at
.github/pull_request_template.md
(GitHub), or in.gitlab/merge_request_templates
folder (GitLab)
Licence
Unless stated otherwise, the codebase is released under the MIT License. This covers both the codebase and any sample code in the documentation. The documentation is © Crown copyright and available under the terms of the Open Government 3.0 licence.
Contributing
If you want to help us build, and improve govcookiecutter
, view our contributing
guidelines.
Acknowledgements
This template is based off the DrivenData Cookiecutter Data Science
project. Specifically, it uses a modified version of the help
commands in the Makefile
s.