Skip to main content

A Python package scaffold

Project description

init-python-package

Minimal, distribution-ready Python package scaffolding.
Generate projects that are instantly installable with pip and publishable to PyPI.

init-python-package helps you bootstrap Python projects with a ready-to-publish structure:

  • Editable install support (pip install -e .)
  • PyPI-compliant metadata (pyproject.toml, SPDX license, README`)
  • Preconfigured tests, scripts, and notebooks

Features

  • Generates a complete PyPI-ready package structure
  • Includes README.md, LICENSE, and pyproject.toml
  • IDE-neutral .gitignore for clean collaboration
  • Modular design for optional flows and diagnostics
  • Emphasis on reproducibility and auditability

Installation

Clone the repository and set up your environment:

git clone https://github.com/your-username/init-python-package.git
cd init-python-package
./setup_env.sh        # or setup_env.bat on Windows
pip install -e .

Alternatively, users can manually create and activate a virtual environment if they prefer.

📦 Usage

Run directly from your terminal:

init-python-package my_new_package

Argument my_new_package is the full path to the generated package. If you omit the path arg, the tool runs in interactive mode and prompts you for the package location.


This creates a new folder with a complete Python package structure, including:

  • Metadata (pyproject.toml, README.md, LICENSE)
  • Importable package directory (my_new_package/)
  • CLI entry point (my_new_package/main.py)
  • Test scaffolding (tests/)
  • Supporting folders (scripts/, notebooks/, data/)

🗂️ Generated Package Structure

my_new_package/
├── my_new_package/           # Importable Python package
│   ├── __init__.py           # Includes dynamic version
│   ├── main.py               # CLI entry point
│   └── tools/                # Helper modules
├── tests/                    # pytest-ready test folder
├── scripts/                  # Example scripts
├── notebooks/                # Example notebooks
├── data/                     # Data folder
├── README.md                 # PyPI-ready long description
├── LICENSE                   # Apache-2.0 license
├── pyproject.toml            # Build metadata
├── .gitignore
├── requirements.txt
├── setup_env.bat / .sh       # Optional environment setup

Project Intent

The goal of this project is to make starting a new Python package as simple and reliable as possible.
Instead of piecing together configuration files, metadata, and test scaffolding by hand,
init-python-package generates a complete, distribution-ready structure that you can install locally
with pip and publish directly to PyPI.

By using this scaffolding, you can:

  • Begin coding immediately without worrying about packaging details.
  • Validate that your project installs cleanly in a fresh environment.
  • Ensure reproducibility with standardized metadata and licensing.
  • Share your work confidently, knowing the structure meets PyPI requirements.

This project is shared publicly in support of the Python open‑source community,
with the hope that it will be useful for learners, researchers, and developers alike.
Contributions are welcome, though please note that pull requests may not be actively reviewed.

Author

George Cutter

Disclaimer

This software is provided “as is”, without warranty of any kind.
The author assumes no responsibility for errors, omissions, or outcomes resulting from its use.
Users are encouraged to validate results independently and adapt workflows to their own requirements.
This project is intended for educational and research purposes and should not be used as a substitute for professional advice in regulated domains (e.g., medical, legal, financial).

License

This project is licensed under the Apache License 2.0.
You may use, modify, and distribute this software under the terms of the Apache License.
See the LICENSE file for the full text.

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

init_python_package-0.1.5.tar.gz (8.5 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

init_python_package-0.1.5-py3-none-any.whl (8.8 kB view details)

Uploaded Python 3

File details

Details for the file init_python_package-0.1.5.tar.gz.

File metadata

  • Download URL: init_python_package-0.1.5.tar.gz
  • Upload date:
  • Size: 8.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.10

File hashes

Hashes for init_python_package-0.1.5.tar.gz
Algorithm Hash digest
SHA256 87a01440911b2c45d5f357dfb1070ebdd7777320e2f683a69dc5aa3a624b442f
MD5 b20bd66c807a5019948901d165c7357d
BLAKE2b-256 ad9ff30387429819990e2566d383a95f7c73c9284658a1ead64177292171d630

See more details on using hashes here.

File details

Details for the file init_python_package-0.1.5-py3-none-any.whl.

File metadata

File hashes

Hashes for init_python_package-0.1.5-py3-none-any.whl
Algorithm Hash digest
SHA256 11f45f33269cd5be8e517ed276f5a862bb2197e5d9fdf3359560d559e90fa974
MD5 f662137103ad7691321aeb3e1b22e7e5
BLAKE2b-256 dae817e49e54fecacf7fffa48822196769217d48693a34a415fa6e3530167d97

See more details on using hashes here.

Supported by

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