Skip to content

martibosch/cookiecutter-geopy-package

Repository files navigation

CI pre-commit.ci status GitHub license

Cookiecutter geopy package

Template for Python packages using GDAL (from conda-forge).

Features

This project template includes the following features to ensure best practices:

  • Overall project configuration: pyproject.toml for PEP-626-compliant project configuration.
  • Tests:
  • Documentation: generated with sphinx, using MyST for Markdown support, auto API generation from docstrings and hosting on readthedocs.
  • Code quality: set up with pre-commit to run checks and tests before each commit, including, among others:
    • black for code formatting.
    • ruff for code linting and formatting.
    • prettier to format configuration files.
  • Continuous integration and delivery with GitHub Actions, with jobs to run tests, publishing to test PyPI and releasing to PyPI and GitHub on new tags.
  • Conventional commits and semantic versioning with commitizen to enforce conventional commits (with commit-msg pre-commit hooks), version bumping using semantic versioning and automated change log generation.

Usage

First time setup

Generate a new project using cookiecutter:

cookiecutter gh:martibosch/cookiecutter-geopy-package

and fill in the prompts. Then, navigate to the generated directory and follow the instructions below:

  • Initialize a git repository (e.g., git init) and install the pre-commit hooks by running pre-commit install and pre-commit install --hook-type commit-msg.
  • Register the project in codecov and readthedocs.
  • If the repository is public, enable pre-commit.ci to automatically run pre-commit checks on GitHub and autoupdate the pre-commit hook versions.
  • Create accounts (or use existing accounts) and API tokens for PyPI and test PyPI, and add them to the project's secrets in GitHub.

You can then start developing your package.

Development

Submit a recipe to conda-forge

If you want your package to be available from conda-forge, you can generate a recipe for it using grayskull and then submit it by following the instructions in the conda-forge documentation.

Acknowledgements

About

cookiecutter-geopy-package

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages