Skip to content

Latest commit

 

History

History
34 lines (21 loc) · 1.12 KB

File metadata and controls

34 lines (21 loc) · 1.12 KB

>_ comrun

PyPI version codecov Docs

comrun (shorthand for command runner) is a simple, configurable wrapper for Python's subprocess.Popen, focused on making it easy to run external commands from Python scripts.

Installation

Add to your project with uv:

uv add comrun

Usage

Just create a CommandRunner instance and call it with the command you want to run:

from comrun import CommandRunner

runner = CommandRunner()

# Run your command – instance is callable
result = runner('echo "The cake is a lie."')

# (prints "The cake is a lie." to the console)

The same runner instance can be reused indefinitely to call other commands.

Full documentation can be found here.