how to truncate lines

Marc Unangst mju at mudos.ann-arbor.mi.us
Tue Feb 19 12:46:49 AEST 1991


In article <1991Feb18.205238.14418 at dartvax.dartmouth.edu> mdm at icefloe.dartmouth.edu (Michael McDaniel) writes:
>I am trying to write a simple shell script that will truncate lines fed
>from the standard input to 80 characters.  I only want the first 80

cat file.with.really.long.lines | cut -c1-80 > file.with.shorter.lines

-- 
Marc Unangst                | "I think I have a bad disk.  Even though I
mju at mudos.ann-arbor.mi.us   |  folded it to fit into my drive, it still
...!umich!leebai!mudos!mju  |  doesn't work..." -Caller to a tech support line



More information about the Comp.unix.programmer mailing list