Skip to content

Minimalistic template that can be used as a base to develop a simple python script that interacts with stdin to take part e.g. on shell pipes.

Notifications You must be signed in to change notification settings

tiagoprn/minimum-viable-python-script

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

18 Commits
 
 
 
 
 
 

Repository files navigation

minimum-viable-python-script

This project is a minimalistic template that can be used as a base to develop a simple pure python script to run on the CLI.

Features

  • A Makefile to wrap the most common operations and ease development with commands to run the script and its' tests, apply formatters, run linters, tests, etc...

  • There is no third-party library dependency (except for development ones), so that you can run your script standalone if you wish.

  • python 3.10

  • poetry as the package manager

  • pylint as the linter, black as the code formatter, isort to fix import order

  • pytest tests, with some plugins to ease presentation.

  • coverage report.

How to use this cookiecutter

  • Install cookiecutter on your distribution (e.g. Ubuntu):

$ sudo apt install cookiecutter

  • Enter the folder where your want to create your script locally:

$ cd ~/projects/

  • Run the cookiecutter from github (recommended):

$ cookiecutter gh:tiagoprn/minimum-viable-python-script

It will ask some questions (which have default values, case you are on a hurry) and generate a folder with the value you indicated for project_slug. Congratulations, this is your new minimal python project! :)

  • Enter the project directory:

$ cd ~/projects/your_project_slug

  • Now follow the instructions on the folder's README.md so that you can setup the development environment.

About

Minimalistic template that can be used as a base to develop a simple python script that interacts with stdin to take part e.g. on shell pipes.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published