/minisetup

Minimalist scaffolding/setup script for Python projects

Primary LanguageShell

Minisetup

Minimalist setup/scaffolding/skeleton framework for Python applications.

Background

I set up a lot of small self-contained applications that need to run on remote machines. While things like Setuptools are excellent and essentially the de-facto standard these days, it is sometimes nice to have a bare-bones solution with minimal boilerplate.

Minisetup is an opinionated self contained setup script that can initialize a Python project with an install/uninstall script and configure it as a systemd service or command line application. Everything is contained in a single bash script that can be comprehended in a few minutes. Once a project skeleton is created, it is easy to add remove functionality based on requirements.

Installation

Clone this repo and simply copy the minisetup script to somewhere in your PATH, i.e.

$> cp minisetup /usr/local/bin/minisetup

Initialization

$> minisetup myproject [TYPE]

Project Types:

The following arguments can be supplied for TYPE (default is cli):

cliCommand line application
servicesystemd service
timersystemd timer service

Usage

Once you have initialized a project, the following actions are available:

Install

Install for development (i.e. install all test/dev dependencies):

$> ./install.sh dev

Install for production:

$> ./install.sh

Uninstall

$> ./uninstall.sh

Linting

$> flake8

Code Formatting

$> black .

Testing

$> pytest

Development

Minisetup is linted using shellcheck

$> shellcheck minisetup