GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — GitHub - tekumara/python-typed-template: A minimal, generic, and opinionated template for typed ✨ python projects

BranchesTags
Open more actions menu

Latest commit

 

History

276 Commits
276 Commits

Folders and files

NameName
Last commit message
Last commit date
.github
.github
 
 
hooks
hooks
 
 
snapshots
snapshots
 
 
{{cookiecutter.repo_name}}
{{cookiecutter.repo_name}}
 
 
.gitignore
.gitignore
 
 
.pre-commit-config.yaml
.pre-commit-config.yaml
 
 
.python-version
.python-version
 
 
.taplo.toml
.taplo.toml
 
 
CONTRIBUTING.md
CONTRIBUTING.md
 
 
DESIGN.md
DESIGN.md
 
 
LICENSE
LICENSE
 
 
Makefile
Makefile
 
 
README.md
README.md
 
 
cookiecutter.json
cookiecutter.json
 
 

Repository files navigation

Python typed template 🐍

Build

A minimal, generic, and opinionated template for typed ✨ python projects that includes:

  • make as a task runner
  • uv for dependency management
  • ruff for linting
  • pyright for type checking
  • pytest for testing
  • pre-commit for running the above as hooks
  • a GHA ci workflow that runs hooks every commit

Type hints are enforced. Uses a flat layout, ie: packages are defined at the top level. Naming conventions are as per PEP8, see Template parameters below. And not much else. This is meant to be generic, so anything specific to only a subset of projects probably lives elsewhere.

For more info see DESIGN.md.

Project development prerequisites

Projects created using this template have development prerequisites.

Template parameters

The template will ask for the following:

  • repo_name: The name of your repo. Repo names are lowered kebab-case, so hyphens rather than underscores, to be kind to humans.
  • package_name: The name of your main python package. A python package is a group of modules, ie: a directory with __init__.py file. Choose a short all-lowercase name without hyphens. The use of underscores is discouraged (see PEP8).
  • project_name: The name of the artifact when your project is built as a wheel. Project names are lowered kebab-case. In most cases the package name and project name will be the same. This is used in pyproject.toml and needed even if you aren't building a wheel.
  • description: a one line description of your project.

Getting started

cruft is recommended for creating projects.

To create a project, aka bake a cookie 🍪, using uv and cruft:

uvx cruft create [email protected]:tekumara/python-typed-template.git
# replace repo-name below with the name you specified during template creation
cd repo-name
git init && git commit -m 'root commit' --allow-empty
make install

Contributing 🌱

Please do! See CONTRIBUTING.md

About

A minimal, generic, and opinionated template for typed ✨ python projects

Topics

cookiecutterpythontemplate

Resources

Readme
MIT license

Contributing

Contributing
Activity

Stars

28 stars

Watchers

1 watching

Forks

7 forks
Report repository

Releases

Packages

Contributors

Languages

You are visitor 01402503 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.