Tue, May 23, 2023
Read in 2 minutes
This is a checklist of the basic steps in order to create a reproducible, flexible, adaptable environment for any kind of python project that has venv and package management using Poetry
pip install poetry
poetry shell
poetry init
[tool.poetry]
name = "project_name"
version = "0.1.0"
description = "project_description"
authors = ["joseporiolayats <oriol.ayats@gmail.com>"]
license = "MIT"
readme = "README.md"
documentation = "https://joseporiolayats.github.io/my-github-repo"
repository = "https://github.com/joseporiolayats/my-github-repo"
keywords = ["tag1","tag2","tag3"]
packages = [{include = "project_name" }]
[tool.poetry.dependencies]
python = "^3.11"
colorlog = "^6.7.0"
python-decouple = "^3.8"
pymdown-extensions = "^10.0.1"
[tool.poetry.group.test.dependencies]
ruff = "^0.0.269"
pytest = "^7.3.1"
pytest-asyncio = "^0.21.0"
[tool.poetry.group.docs.dependencies]
mkdocs = "^1.4.3"
mkdocs-material = "^9.1.14"
mkdocstrings-python = "^1.0.0"
[tool.poetry.group.linst.dependencies]
black = "^23.3.0"
[build-system]
requires = ["poetry-core"]
build-backend = "poetry.core.masonry.api"
pyproject.toml
using the [tool.poetry.dependencies]
section.poetry install
poetry update
git remote add origin <repository-url>
git push -u origin main
pip install pre-commit
.pre-commit-config.yaml
file in the project root.pre-commit install
to enable the pre-commit hooks.README.md
and docs/
.