3 ms·
BSD has a progress meter utility. It's called progress(1). progress -zf /data/*.log.gz grep -c 'hello world' progress -f /data/*.log.gz zgrep -c 'hello
by gwu78 13y ago
BSD has a progress meter utility. It's called progress(1).
progress -zf /data/*.log.gz grep -c 'hello world'
progress -f /data/*.log.gz zgrep -c 'hello world'
The second form will show the progress of the decompression process.
You can also adjust buffer size, set the length for the time estimate (otherwise we have to fstat the input), and display progress to stderr instead of stdout.
- gaadd33 13y agoWhich BSD has that? I don't seem to find it in my FreeBSD installs.
- gwu78 13y agoIt's actually in FreeBSD's base, but it's part of the ftp(1) program. http://svnweb.freebsd.org/base/vendor/tnftp/dist/src/progressbar.c http://ftp.netbsd.org/pub/NetBSD/NetBSD-release-6/src/usr.bin/{Makefile,progress.c} Not sure if you prefer binary installs or whether you compile your installs yourself... but I'm sure you could get this to compile on FreeBSD with a little work.