>>>>> "Alexandre" == Alexandre Oliva <[EMAIL PROTECTED]> writes:

Alexandre> I'm not even sure `wc -c' will be available everywhere :-(

I don't remember where, but I used it portably.  I think for a time,
Automake what using it too somewhere (was it depcomp?).  But I can't
find where.

To answer Mo's question, the means to get the size of a file I used
was

        size=`cat file | wc -c`

so that wc does not give the name.  Alternatively,

        set dummy `wc file`
        size=$3

should be fine.

But I prefer the approach presented by Paul, based on ls, which is
properly much faster.

Alexandre> I still think using cmp is the best solution.

I trust wc -c more than I trust tail +16c.

Reply via email to