Python Project Template

screenshot of Python Project Template
flask

Python Project Template

DO NOT FORK, CLICK ON "Use this template" - A github template to start a Python Project - this uses github actions to generate your project based on the template.

Overview:

The Python Project Template is a low dependency and simple to start project template for Python Projects. It provides various features and tools to help with the development and management of Python projects.

Features:

  • Templates for starting multiple application types: The template includes templates for a basic low dependency Python program, as well as templates for Flask applications with database, admin interface, rest API, and authentication.
  • Basic setup.py file: The template includes a basic setup.py file that provides installation, packaging, and distribution for your project.
  • Makefile with useful commands: The template includes a Makefile with commands to install, test, lint, format, and release your project.
  • Documentation structure using mkdocs: The template includes a documentation structure using mkdocs, making it easy to create and maintain project documentation.
  • Auto generation of change log: The template automatically generates a change log file based on your commit history on every release, using gitchangelog.
  • Container image support: The template includes a simple Containerfile that can be used to build a container image for your project.
  • Testing structure using pytest: The template provides a testing structure using pytest, making it easy to write and run tests for your project.
  • Code linting using flake8: The template includes code linting using flake8, helping to enforce code style and maintainability.
  • Code coverage reports using codecov: The template supports code coverage reports using codecov, allowing you to track the coverage of your tests.
  • Automatic release to PyPI: The template includes automatic release to PyPI using twine and GitHub actions, simplifying the release process.
  • Entry points for program execution: The template provides entry points to execute your program using python -m <project_name> or $ project_name with basic CLI argument parsing.
  • Continuous integration using Github Actions: The template includes continuous integration using GitHub Actions, with jobs to lint, test, and release your project on Linux, Mac, and Windows environments.

Installation:

To use this template, do not fork it. Instead, follow these steps:

  1. Click on the "Use this template" button.
  2. Give a name to your project (recommendation is to use all lowercase and underscores separation for repo names).
  3. Wait until the first run of CI finishes (GitHub Actions will process the template and commit to your new repo).
  4. If you want codecov Reports and Automatic Release to PyPI, go to your new repository settings->secrets and add your PYPI_API_TOKEN and CODECOV_TOKEN (get the tokens on respective websites).
  5. Read the file CONTRIBUTING.md.
  6. Clone your new project and start coding.

Note: Wait until the first CI run on GitHub Actions before cloning your new project.

Summary:

The Python Project Template is a convenient starting point for Python projects. It provides a simple and low-dependency template with various features and tools for development, testing, documentation, and release management. With its pre-configured setup, the template allows developers to quickly start working on their projects and focus on coding rather than setting up a project structure from scratch.

flask
Flask

Flask is a lightweight and popular web framework for Python, known for its simplicity and flexibility. It is widely used to build web applications, providing a minimalistic approach to web development with features like routing, templates, and support for extensions.

fullstack
Fullstack Boilerplates

A fullstack boilerplate provides a starter application that includes both frontend and backend. It should include database, auth, payments, user roles and other backend services to build a fully featured saas or webapps.

template
Templates & Themes

A template or theme refers to a pre-designed layout or structure that provides a basic framework for building a specific type of application or website. It typically includes good design, placeholder content and functional features, allowing developers to customize and fill in the details according to their specific needs.