Skip to content
Snippets Groups Projects

cookiecutter-pypackage

Cookiecutter template for a Python package. Based on github.com/audreyr/cookiecutter.

  • Pytest runner: Supports pytest, test coverate, style tests and more
  • Gitlab-CI: Ready for Gitlab Continous Integration testing
  • Tox testing: Setup to easily test for latest python versions
  • Sphinx docs: Documentation ready for generation with, for example, ReadTheDocs

Usage

Generate a Python package project::

cookiecutter https://cosmo-gitlab.phys.ethz.ch/cosmo/cookiecutter-pypackage

Then:

  1. Create your repo on cosmo-gitlab.ethz.ch and look for the command git remote add .. in the shown list of instructions.
  2. Run this command in your folder,
  3. Run git push --set-upstream origin main and check on gitlab if the CI pipeline runs and succeeds.