Skip to main content

Downloads, Installs in paralell - A utility to run multiple shell command sequences (e.g., installations) in parallel with status updates.

Project description

Bolt the Builder Bot - RapidInstall Mascot

rapidinstall

PyPI version

License: GPL v3

A simple Python utility to run multiple shell command sequences (e.g., complex installations, downloads, build steps) in parallel, providing status updates and aggregated output directly to the console.

Features

  • Parallel Execution: Runs multiple tasks concurrently using subprocess.
  • Real-time Output: Captures stdout and stderr from tasks.
  • Status Updates: Periodically shows which tasks are still running and recent output.
  • Clear Formatting: Presents startup, status, and completion information in distinct blocks.
  • Simple API: Easy to integrate into existing Python scripts.
  • Pure Python: Relies only on the standard library.

Installation

pip install rapidinstall

Example: first look

import rapidinstall

my_tasks = [
    {'name': 'Pip', 'commands': 'pip install this that'},
    {'name': 'Download MyFile', 'commands': "wget https://my.file/is_here"}
]

rapidinstall.install(my_tasks)

Downloads and Installs in paralell and updates you on the progress

Example: typical

import rapidinstall

clone_and_install = '''clone https://github.com/tomOfBerlin/rapidinstall
cd rapidinstall
python setup.py install
cd ..'''

my_tasks = [
    {'name': 'Pip', 'commands': 'pip install this that'},
    {'name': 'Download MyFile', 'commands': "wget https://my.file/is_here"},
	{'name': 'Clone and install Dependencies', 'commands': clone_and_install}
]

rapidinstall.install(my_tasks)

You can execute commands sequentially, great for git installs.

Example: silent

# Completely silent - verbose is turned on by default
rapidinstall.install(my_tasks, verbose=False)

# Updates every 60 seconds
rapidinstall.install(my_tasks, update_interval=60)

Example: advanced

# Import directly from the run module (previously executor)
from rapidinstall.run import run_tasks
# You can also access constants like:
# from rapidinstall.run import DEFAULT_STATUS_UPDATE_INTERVAL

task_a = {'name': 'Task A', 'commands': 'echo "Executing A"; sleep 1'}
task_b = {'name': 'Task B', 'commands': 'echo "Executing B"; sleep 1'}

print("\n--- Starting Advanced Example (run_tasks) ---")
# Pass arguments directly to run_tasks
results_advanced = run_tasks(todos=[task_a, task_b], verbose=True, update_interval=10)
print("--- Advanced Example Finished ---")

print("\n--- Task Execution Summary (Advanced) ---")
print(results_advanced) # Print the raw results dictionary

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

rapidinstall-0.9.1.tar.gz (22.3 kB view details)

Uploaded Source

Built Distribution

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

rapidinstall-0.9.1-py3-none-any.whl (21.3 kB view details)

Uploaded Python 3

File details

Details for the file rapidinstall-0.9.1.tar.gz.

File metadata

  • Download URL: rapidinstall-0.9.1.tar.gz
  • Upload date:
  • Size: 22.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.10.15

File hashes

Hashes for rapidinstall-0.9.1.tar.gz
Algorithm Hash digest
SHA256 4c09b9edc26c6b68c28a3a959747490fd785fdf96c8e6d1216175f2b3eed361c
MD5 972a7b0ebfcd71d5015b8048ced6120c
BLAKE2b-256 2c02d56988671e0cbc6cd97b15a1a5d6abf132724e94b6bb8d2250fe7fd809be

See more details on using hashes here.

File details

Details for the file rapidinstall-0.9.1-py3-none-any.whl.

File metadata

  • Download URL: rapidinstall-0.9.1-py3-none-any.whl
  • Upload date:
  • Size: 21.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.10.15

File hashes

Hashes for rapidinstall-0.9.1-py3-none-any.whl
Algorithm Hash digest
SHA256 f36f87bbc76b49e9621ade2f16595e616947476aa559ed749b11a9e5641750ce
MD5 a69d4de30d6dafc11fee9495c36d37d4
BLAKE2b-256 18afedbccacdfb500be93e3916ae2a2698a1cb362bdf0c209624bd24e2bcd505

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