cmdprogress
Cross Platform Python Command Line Progress Bars
MacOS
Windows
Linux
Contents
Installation
Use pip via PyPi
pip install cmdprogress
Or use git
git clone git://github.com/luciancooper/cmdprogress.git cmdprogress
cd cmdprogress
python setup.py install
Usage
this project consists of two instantiatable classes: ProgBar and MultiBar
ProgBar
There are two ways to use a ProgBar
Either give it a length when you instantiate the object, and then directly loop through it
from cmdprogress.bar import ProgBar
bar = ProgBar(max=5)
for x in bar:
# x = (0 .. 5)
# do some work
Or do not provide it a length when you instantiate it, instead provide it an iterable to wrap
from cmdprogress.bar import ProgBar
bar = ProgBar()
for x in bar.iter(range(5)):
# x = (0 .. 5)
# do some work
MultiBar
There are 3 ways to use a MultiBar.
from cmdprogress.multi import MultiBar
bar = MultiBar(lvl=2)
for i in bar.iter(range(5)):
for j in bar.iter(range(10)):
# do some work
from cmdprogress.multi import MultiBar
bar = MultiBar(5,lvl=2)
for x in range(5):
for i in bar.iter(range(10)):
# do some work
from cmdprogress.multi import MultiBar
bar = MultiBar(5,10)
for x in bar:
# x will be the tuple (i,j)
# do some work
Acknowledgements
- This project depends on colorama to work in the Windows Command Line
- Shoutout to this stack overflow answer
Metadata
Release files for cmdprogress 1.2
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | |
|---|---|---|---|---|
| cmdprogress-1.2.tar.gz | 5.4 kB | Without provenance | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| cmdprogress-1.2-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 12.9 kB
Release files / cmdprogress-1.2.tar.gz
| Download URL | cmdprogress-1.2.tar.gz |
|---|---|
| Size | 5.4 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
4c536b62d771339a61d5c70872ceaa6f18c6477fe2f5b5f6d85bd85a52a8d491
|
|
BLAKE2b-256 checksum How to use checksums |
668ac91ca7b9f2d98353558858c0ce0a517cf40ac4530fe6df9ae97fb765cae5
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/1.12.1 pkginfo/1.4.2 requests/2.14.2 setuptools/40.6.2 requests-toolbelt/0.8.0 tqdm/4.24.0 CPython/3.6.1
|
Release files / cmdprogress-1.2-py3-none-any.whl
| Download URL | cmdprogress-1.2-py3-none-any.whl |
|---|---|
| Size | 7.5 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
730b6e6758d6f3fcb5c95279e8698fab76fcdce698fa8da9d4161a1c529d4c0d
|
|
BLAKE2b-256 checksum How to use checksums |
c0399d73d7e37ba5300d0cd38040de4db278c5207fb408aa3f574cc7b3cfb02f
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/1.12.1 pkginfo/1.4.2 requests/2.14.2 setuptools/40.6.2 requests-toolbelt/0.8.0 tqdm/4.24.0 CPython/3.6.1
|
Security for cmdprogress 1.2
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.