diff --git a/.meta/.readme.rst b/.meta/.readme.rst index 75d83a6a..0419c9ac 100644 --- a/.meta/.readme.rst +++ b/.meta/.readme.rst @@ -215,7 +215,7 @@ Perhaps the most wonderful use of ``tqdm`` is in a script or on the command line. Simply inserting ``tqdm`` (or ``python -m tqdm``) between pipes will pass through all ``stdin`` to ``stdout`` while printing progress to ``stderr``. -The example below demonstrated counting the number of lines in all Python files +The example below demonstrate counting the number of lines in all Python files in the current directory, with timing information included. .. code:: sh @@ -247,7 +247,7 @@ Backing up a large directory? .. code:: sh - tar -zcf - docs/ | tqdm --bytes --total `du -sb docs/ | cut -f1` \ + $ tar -zcf - docs/ | tqdm --bytes --total `du -sb docs/ | cut -f1` \ > backup.tgz 44%|██████████████▊ | 153M/352M [00:14<00:18, 11.0MB/s] @@ -255,8 +255,8 @@ This can be beautified further: .. code:: sh - BYTES="$(du -sb docs/ | cut -f1)" - tar -cf - docs/ \ + $ BYTES="$(du -sb docs/ | cut -f1)" + $ tar -cf - docs/ \ | tqdm --bytes --total "$BYTES" --desc Processing | gzip \ | tqdm --bytes --total "$BYTES" --desc Compressed --position 1 \ > ~/backup.tgz @@ -267,7 +267,7 @@ Or done on a file level using 7-zip: .. code:: sh - 7z a -bd -r backup.7z docs/ | grep Compressing \ + $ 7z a -bd -r backup.7z docs/ | grep Compressing \ | tqdm --total $(find docs/ -type f | wc -l) --unit files \ | grep -v Compressing 100%|██████████████████████████▉| 15327/15327 [01:00<00:00, 712.96files/s] @@ -277,9 +277,9 @@ benefit from ``tqdm``'s ``--update`` and ``--update_to`` flags: .. code:: sh - seq 3 0.1 5 | tqdm --total 5 --update_to --null + $ seq 3 0.1 5 | tqdm --total 5 --update_to --null 100%|████████████████████████████████████| 5.0/5 [00:00<00:00, 9673.21it/s] - seq 10 | tqdm --update --null # 1 + 2 + ... + 10 = 55 iterations + $ seq 10 | tqdm --update --null # 1 + 2 + ... + 10 = 55 iterations 55it [00:00, 90006.52it/s] FAQ and Known Issues diff --git a/README.rst b/README.rst index ac43c547..51901f6b 100644 --- a/README.rst +++ b/README.rst @@ -215,7 +215,7 @@ Perhaps the most wonderful use of ``tqdm`` is in a script or on the command line. Simply inserting ``tqdm`` (or ``python -m tqdm``) between pipes will pass through all ``stdin`` to ``stdout`` while printing progress to ``stderr``. -The example below demonstrated counting the number of lines in all Python files +The example below demonstrate counting the number of lines in all Python files in the current directory, with timing information included. .. code:: sh @@ -247,7 +247,7 @@ Backing up a large directory? .. code:: sh - tar -zcf - docs/ | tqdm --bytes --total `du -sb docs/ | cut -f1` \ + $ tar -zcf - docs/ | tqdm --bytes --total `du -sb docs/ | cut -f1` \ > backup.tgz 44%|██████████████▊ | 153M/352M [00:14<00:18, 11.0MB/s] @@ -255,8 +255,8 @@ This can be beautified further: .. code:: sh - BYTES="$(du -sb docs/ | cut -f1)" - tar -cf - docs/ \ + $ BYTES="$(du -sb docs/ | cut -f1)" + $ tar -cf - docs/ \ | tqdm --bytes --total "$BYTES" --desc Processing | gzip \ | tqdm --bytes --total "$BYTES" --desc Compressed --position 1 \ > ~/backup.tgz @@ -267,7 +267,7 @@ Or done on a file level using 7-zip: .. code:: sh - 7z a -bd -r backup.7z docs/ | grep Compressing \ + $ 7z a -bd -r backup.7z docs/ | grep Compressing \ | tqdm --total $(find docs/ -type f | wc -l) --unit files \ | grep -v Compressing 100%|██████████████████████████▉| 15327/15327 [01:00<00:00, 712.96files/s] @@ -277,9 +277,9 @@ benefit from ``tqdm``'s ``--update`` and ``--update_to`` flags: .. code:: sh - seq 3 0.1 5 | tqdm --total 5 --update_to --null + $ seq 3 0.1 5 | tqdm --total 5 --update_to --null 100%|████████████████████████████████████| 5.0/5 [00:00<00:00, 9673.21it/s] - seq 10 | tqdm --update --null # 1 + 2 + ... + 10 = 55 iterations + $ seq 10 | tqdm --update --null # 1 + 2 + ... + 10 = 55 iterations 55it [00:00, 90006.52it/s] FAQ and Known Issues