aboutsummaryrefslogtreecommitdiff
path: root/stdu.1
diff options
context:
space:
mode:
authorJoel Kronqvist <joel.kronqvist@iki.fi>2024-05-31 15:29:42 +0300
committerJoel Kronqvist <joel.kronqvist@iki.fi>2024-06-30 08:31:37 +0300
commit576b7a70dbf6c43651dc77db3a0104c019eed018 (patch)
tree6ca087eb2e3bd27d876ad2842d67cee2d7e09cbf /stdu.1
parent41de123de0453274fb2e5b2192548ce274ad8deb (diff)
downloadstdu-576b7a70dbf6c43651dc77db3a0104c019eed018.tar.gz
stdu-576b7a70dbf6c43651dc77db3a0104c019eed018.zip
Added `--forward`work/1.1.0
Diffstat (limited to 'stdu.1')
-rw-r--r--stdu.128
1 files changed, 25 insertions, 3 deletions
diff --git a/stdu.1 b/stdu.1
index 79fbcba..5693270 100644
--- a/stdu.1
+++ b/stdu.1
@@ -1,16 +1,17 @@
-.Dd 2024-04-14
+.Dd 2024-05-31
.Dt STDU 1
.Sh NAME
.Nm stdu
.Nd monitor amount of data read from stdin
.Sh SYNOPSIS
.Nm stdu
+.Op Fl Fl forward
.Op Fl Fl help
.Op Fl Fl human-readable
.Op Fl Fl multiline
.Op Fl Fl precision Ar n
.Nm stdu
-.Op Fl hm?
+.Op Fl hmo?
.Op Fl p Ar n
.Sh DESCRIPTION
.Nm
@@ -23,6 +24,9 @@ in chunks) if \fB--precision\fR or \fB--human-readable\fR aren't specified,
so specifying them is recommended.
.Sh OPTIONS
.Bl -tag -width 3n
+.It Fl Fl forward | Fl o
+Writes data read from STDIN to STDOUT and prints amount of read data
+to STDERR instead of STDOUT.
.It Fl Fl help | Fl ?
Displays a help message.
.It Fl Fl human-readable | Fl h
@@ -43,9 +47,27 @@ may add trailing zeroes.
.Sh EXAMPLES
.Nm
is useful as a progress bar replacement when transmitting large files.
-.Bd -literal
+.Bd -literal -offset indent
nc -l 1234 | tee backup.tar.gz | stdu -p3 -h
.Ed
+.Bd -literal -offset indent
+cat void-live-x86_64-musl-base.iso | stdu -ho > /dev/sdb1
+.Ed
+.Sh CAVEATS
+.Bd -literal -offset indent
+cat void-live-x86_64-musl-base.iso | sudo tee /dev/sdb1 | stdu -p3
+.Ed
+
+Is not very informative because
+.Nm
+probably reads the data faster from
+.Xr tee 1
+than /dev/sdb1 does. This is why
+.Ar forward
+has been implemented.
.Sh "SEE ALSO"
+.Xr dd 1
.Xr du 1
+.Xr progress 1
+.Xr pv 1