Skip to content

Workata/pyplate

Repository files navigation

Python 3.14 uv Ruff ty prek Renovate enabled security: bandit License: MIT Contributions PyPlate stars

pyplate logo

About the project

Template for a standard (non-framework related) python project. The point of this repo is to have a basic project layout with working CI/CD and integrated common python tools. It should be later on adjusted according to the needs of specific project.

Integrated tools

  • uv (python project manager)
  • ruff (formatter)
  • ruff (linter)
  • ty (type checker)
  • bandit (security checks)
  • pytest (unit tests)
  • pydantic (data validation, models)
  • pydantic-settings (settings management)
  • prek (git hooks, running checks)
  • just (command runner* - easily run tests/checks/application) - optional

* to enable autocompletion of declared commands follow the docs. For Ubuntu with bash do the following:

sudo apt install bash-completion
mkdir -p ~/.local/share/bash-completion/completions
just --completions bash > ~/.local/share/bash-completion/completions/just

Development

Requirements

  • uv - python project manager (required)

Setup

Install uv

curl -LsSf https://astral.sh/uv/install.sh | sh

Verify uv installation

uv --version

After the uv installation you can init the setup

uv sync
uv run just init

or simply just init if you have just installed.


To setup the project manually check the following:

Copy example env file

cp -n .env.example .env

Create new venv and sync packages (base + dev)

uv sync

Activate venv

. ./.venv/bin/activate

Enable Prek - pre-commit git hook

prek configuration is enabled for this project. To run the hooks every time you commit, install prek’s git hook integration:

prek install

Check and test code

On every commit code should be static tested/checked/formatted automatically (using pre-commit tool).

You can run static checks using

just check

To run unit tests use

just test

Dockerize

Build image

docker build . --tag pyplate-image

Create container and run it

docker run pyplate-image

You can also use provided docker-compose

docker compose build
docker compose up

About

Template for a standard python project + CI

Resources

License

Contributing

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors