euglug.org

[Eug-lug] size of files from a shell script, portably

작성자

카테고리:



Bob MillerThu Dec 9 09:29:23 PST 2004

Jacob Meuser wrote:

> well, I didn't know about wc -c, thanks.  however, the output,
> at least on my system, is not easily parsable, as it is oddly
> aligned, with varying amounts of space.

If you use "wc -c < file" instead of "wc -c file" then wc
doesn't print the file name.

-- 
Bob Miller                              K<bob>
kbobsoft software consulting
http://kbobsoft.com                     kbob at jogger-egg.com