Skip to main content

ppcli

PyPI - Version PyPI - Python Version


ppcli stands for pyproject CLI. It is a Python package designed to provide an easy way to specify and manage auxiliary commands within a pyproject.toml file for any Python project.

Purpose

The primary purpose of ppcli is to allow developers to define and manage common project tasks, such as test, lint, and migration commands, directly within the pyproject.toml file. This ensures that all project-specific commands are centralized and easily accessible.

Installation

You can install ppcli via pip:

pip install ppcli

Usage

After installing ppcli, you can define your project-specific commands within your pyproject.toml file under the [tool.ppcli] section.

Example pyproject.toml Configuration

[tool.ppcli]
lint="black --check --diff ."
fmt="black ."
clean = [
    "find . -type d -name __pycache__ -empty -print0 | xargs --null --no-run-if-empty rmdir",
    "coverage erase",
]
test = [
    "clean",
    "pytest --cov --blockage -x -s --no-header -ra",
]

Defining and Combining Commands

  • Single Command: Each key under [tool.ppcli] represents a command that can be executed. The value can be a single command string or a list of commands.
  • Combined Commands: Use the keys of other commands to create combined tasks. In the example above, the test command executes the clean command followed by pytest.

Running Commands

To execute the defined commands, simply run the ppcli tool followed by the command name:

ppcli <command>

For example:

ppcli lint
ppcli fmt
ppcli test

Contributing

Contributions are welcome! Please open an issue or a pull request to contribute.

License

This project is licensed under the MIT License. See the LICENSE file for more details.

Metadata

Release files for ppcli 0.0.2

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for ppcli 0.0.2
File Size Uploaded
ppcli-0.0.2.tar.gz 5.3 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for ppcli 0.0.2
File Interpreter ABI Platform
ppcli-0.0.2-py3-none-any.whl Python 3 none any Details

Total release size: 10.5 kB

Release files / ppcli-0.0.2.tar.gz

Download URL ppcli-0.0.2.tar.gz
Size 5.3 kB
Tags Source
SHA-256 checksum
How to use checksums
b784842dc60491b717145aa758d372c78837e6b34b47fed88c8afeb9c7ba3e6e
BLAKE2b-256 checksum
How to use checksums
b4f9005d5c02347bdcbc3f121f29b440bb0ef37fbafd64f56f4cf2acac88d9a5
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via python-httpx/0.27.2

Release files / ppcli-0.0.2-py3-none-any.whl

Download URL ppcli-0.0.2-py3-none-any.whl
Size 5.3 kB
Tags Python 3
SHA-256 checksum
How to use checksums
6094dd2c49b8d1dfee9201ea5ff81724b3f9ae1095c670ad912cbfa19cf28abe
BLAKE2b-256 checksum
How to use checksums
f228c6ef915dbbd927b22febd2a57bdbeebed7176bb152e9ff6bdbbf17e96722
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via python-httpx/0.27.2
Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page