Skip to main content

An opinionated Python package template generator

Project description

pypk

An opinionated Python packaging template generator.

Overview

pypk autogenerates a complete python package skeleton that is installable out of the box. It assumes the following tools are used in your development workflow:

However, once the template is generated, pypk gets out of your way, so you are free to add and/or remove tools, frameworks, and libraries as needed.

Installation

pip install pypk

Getting Started

It's recommended you install and use pypk in the same virtual environment you plan to develop your Python package in.

Project Creation

To create a new skeleton project, run the create command:

pypk create </path/to/project/root> -a <author-name> -e <author-email>

Additionally, you can pass the following arguments:

  • -c/--config: a json config file (see the Configuration section).
  • -d/--description: set the package description in the generated setup.py
  • -p/--py-version: set the minimum Python version supported by the project.
  • --init-git/--skip-git-init: initialize git in the generated project (or skip it).
  • --create-tests-dir/--skip-tests-dir: create a top level tests directory in the generated project (or skip it).

Run pypk create --help for more details.

Configuration

pypk supports a configuration which holds (default) parameters for project creation. Specifically, the following parameters can be set in a json config file:

  • author (key=author)
  • email (key=email)
  • description (key=description)
  • py-version (key=py_version)
  • init-git (key=init_git)
  • create-tests-dir (key=tests_dir)

Additionally, default values can be set via the cli so they do not need to be specified whenver the create command is run. pypk will create a json file under the user config dir as defined by appdirs. To set a value, run the following:

pypk config <key> <value>

To print out the currently set value, run:

pypk config <key>

License

MIT

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

pypk-0.6.0.tar.gz (14.5 kB view details)

Uploaded Source

Built Distribution

pypk-0.6.0-py3-none-any.whl (12.6 kB view details)

Uploaded Python 3

File details

Details for the file pypk-0.6.0.tar.gz.

File metadata

  • Download URL: pypk-0.6.0.tar.gz
  • Upload date:
  • Size: 14.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.8.0 pkginfo/1.8.2 readme-renderer/32.0 requests/2.27.1 requests-toolbelt/0.9.1 urllib3/1.26.8 tqdm/4.62.3 importlib-metadata/4.2.0 keyring/23.4.1 rfc3986/1.5.0 colorama/0.4.4 CPython/3.6.13

File hashes

Hashes for pypk-0.6.0.tar.gz
Algorithm Hash digest
SHA256 1e9ba476a1f59e61039f3f5c19d4563d3d900a1b35ad86dab1f12c8992aab576
MD5 7168afa0fc631f028d7536e626ff6637
BLAKE2b-256 8944750946059d5fbb3d43ef44b575ff794c79eb94ba494fe99c4da28e230169

See more details on using hashes here.

File details

Details for the file pypk-0.6.0-py3-none-any.whl.

File metadata

  • Download URL: pypk-0.6.0-py3-none-any.whl
  • Upload date:
  • Size: 12.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.8.0 pkginfo/1.8.2 readme-renderer/32.0 requests/2.27.1 requests-toolbelt/0.9.1 urllib3/1.26.8 tqdm/4.62.3 importlib-metadata/4.2.0 keyring/23.4.1 rfc3986/1.5.0 colorama/0.4.4 CPython/3.6.13

File hashes

Hashes for pypk-0.6.0-py3-none-any.whl
Algorithm Hash digest
SHA256 97d5ba75516d69029061914187e1cd5ab24dbacd15ede2ad65dfbfabe6e6e55f
MD5 abbd7fe983d3973e38c6e18e9779f184
BLAKE2b-256 073ad934cdbe98fc496097995d5abd4adcf1d51b7fb8b53beda2e374c0dfeb04

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page