Skip to content

Commit

Permalink
tqdm: add examples
Browse files Browse the repository at this point in the history
  • Loading branch information
BuonOmo committed Feb 20, 2025
1 parent f6909a0 commit 93147ec
Showing 1 changed file with 10 additions and 2 deletions.
12 changes: 10 additions & 2 deletions pages/common/tqdm.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,16 @@
# tqdm

> Create a progress bar.
> Show progress over time of a command.
> More information: <https://tqdm.github.io/>.
- Show iterations per second and use stdout afterwards:

`{{seq 10000000}} | tqdm | {{command}}`

- Create a progress bar:

`seq 10000000 | tqdm --total 10000000 --null`
`{{seq 10000000}} | tqdm --total 10000000 | {{command}}`

- Specify unit and total:

`tar -zcf - {{docs/}} | tqdm --bytes --total $(du -sb {{docs/}} | cut -f1) > {{backup.tgz}}`

0 comments on commit 93147ec

Please sign in to comment.