Commit Graph

23 Commits

Author SHA1 Message Date
lukem 3d05e3a2bc Update example to use KiB per recent change to ../ftp/progressbar.c 2007-04-12 06:31:20 +00:00
hubertf 79b63fa656 #include inttypes.h, for strtoimax(3).
Suggested by Slava Semushin <slava.semushin@gmail.com> in private email.
2007-02-07 15:21:21 +00:00
hubertf 1a7e106bf0 * Remove unneeded ctype.h
* remove unneeded {}s
* add some whitespace for readability

Contributed by Slava Semushin <slava.semushin@gmail.com> in private mail.
2007-02-07 14:06:57 +00:00
hubertf ce8f04b19d Don't try to determining the size of what's coming when reading from a pipe.
Instead of reporting some bogus values, print no progress at all.
(It's beyond me why stat(2) on a pipe returns funny values...
 see the PR below for some examples!)

Fixes PR bin/33207 by myself.

OK'd by mrg@
2006-04-20 23:20:55 +00:00
wiz 1f5df3a237 Bump date for -e. 2006-01-12 21:52:01 +00:00
garbled ddd39082c1 Apply patch from PR bin/28717
This adds a -e option to progress which causes the progress bar to be
sent to stderr.  This allows using progress mid-pipe, such as:
tar -cf . | progress -e bzip -1c | ssh host "cat > file"
2006-01-12 20:33:20 +00:00
dsl 8d3b64e3cb Exit with any failure code from the cmd or gzip.
Decode gzip -l output with strtoimax() (not sscanf()) so we don't use an
uninitialised variable if the output format isn't what we expect.
This might fix some installation PRs (no error being reported)
2005-02-23 22:32:31 +00:00
lukem f9f551db32 Support strsuftoll(3) suffixes for '-l length'.
Provide an example of copying raw disks using dd, with a progress bar.
2004-04-03 06:19:22 +00:00
hubertf 89cb93c02e -z actually passes the input file through gunzip(1).
Having an option to really pass it through gzip(1) would be nice...
2004-03-25 20:29:51 +00:00
wiz 610cd4021b Drop trailing whitespace. 2004-03-09 19:04:09 +00:00
hubertf 849866f9c1 Allow custom text printed before (left of) the progress bar from progress(1):
miyu# cat openoffice-linux-1.1.0.tgz | progress -z -p 'Bytes written: ' dd of=/dev/null bs=1m
	Bytes written:    193 MB   13.83 MB/s 0+195211 records in
and:
	miyu# progress -f openoffice-linux-1.1.0.tgz -z -p 'Bytes written: ' dd of=/dev/null bs=1m
	Bytes written:  28% |******                | 57919 KB   14.12 MB/s    00:09 ETA

OK'd by lukem.
2004-03-09 17:04:24 +00:00
grant 2ceb845887 The correct capitalisation of 'NetBSD.org' is (you
guessed it) 'NetBSD.org'.

some mdoc fixes.
2003-02-14 15:59:16 +00:00
ross 0328c52302 Sigh, use an even more elaborate wait loop; it turns out we have a child
before we even start when run from sysinst. Thanks also Takao Shinohara.
2003-02-12 00:58:34 +00:00
grant 4352e01ddb remove section name comments -- they're in the template. 2003-02-10 23:59:16 +00:00
ross 182f33ad44 Fix a race that can abort a sysinst run.
Closes bin/20275, thank you Takao Shinohara: good analysis.

This program appeared less than 3 weeks ago and it has already been
pulled up to 1.6.1?  At the last minute?  And with serious bugs?
ISTM that the release branch isn't supposed to work that way. It
isn't stable, it had 4 patches in 2 days, and has averaged a
patch every 4 days during its short lifetime.
2003-02-10 09:10:01 +00:00
agc 24b6883844 Make this build on non-i386 platforms. 2003-01-22 10:44:17 +00:00
jhawk 252f8847d5 Drop gratuitous warning for failure to get terminal width; it makes piping
progress' output ugly.
2003-01-22 04:11:34 +00:00
enami cb5a2282ea Remove second item in BUGS section; it is fixed in progress.c rev. 1.2. 2003-01-22 03:40:33 +00:00
christos 18350cdfbe not all windows have 80 columns. 2003-01-22 03:24:21 +00:00
enami 23066b7faf Advance a pointer correctly. 2003-01-22 03:13:32 +00:00
lukem 8d469d6c4b use ftp(1) instead of lukemftp 2003-01-22 02:58:16 +00:00
lukem b489ebc3bf need bsd.own.mk for NETBSDSRCDIR 2003-01-22 02:56:30 +00:00
jhawk 98f6cccbef progress(1) is a standalone version of lukemftp's progress bar
(pulled in via reachover makefile) suitable for measuring the
input to arbitrary pipes.
This is intended for use by sysinst.
2003-01-22 00:14:12 +00:00