[ILUG] preventing piped output being clipped
diamond at skynet.ie
Wed Sep 5 13:31:59 IST 2001
Something has been annoying me for quite some time now, and I hope
some of ye uber linux people can suggest a solution. Basically I'm piping
the output of 'w' into another command - but it seems to insist in only
outputing 80 chars width. To see what I mean vi a file with a long file
name (anything greater than 11 will do) - this is just so the output of w
will be greater than 80 chars. Then type w in a seperate terminal - and it
works fine. However if you do 'w | less' or 'w > bla' you'll find that
you're missing the end of that line. Now I assume this is because w is
trying to be smart and is using isatty() on stdout. If so, is there anyway
I can beat it into ignoring that, or any other solution?
"My mom had Windows at work and it hurt her eyes real bad"
More information about the ILUG