From luvisi@andru.sonoma.edu Sun Oct 6 21:48:19 1996 Path: fu-berlin.de!news.mathworks.com!enews.sgi.com!news.sgi.com!newshub.sdsu.edu!newshub.csu.net!andru.sonoma.edu!luvisi From: luvisi@andru.sonoma.edu (Andru Luvisi) Newsgroups: comp.editors Subject: Re: What....Another question? Date: 6 Oct 1996 20:37:51 GMT Organization: not much Lines: 15 Distribution: inet Message-ID: <5395av$luh@nuke.csu.net> References: <538d8a$64l@herald.concentric.net> NNTP-Posting-Host: andru.sonoma.edu X-Newsreader: TIN [version 1.2 PL2] Joe Despres (jdespres@concentric.net) wrote: : Question: How would one delete all characters beyond the 80 character : mark on a line using SED? I know how to do it with "cut" & "fold". : But I would like to do it with SED. Can it be done with Awk as well? : Thank you!!!!!....... : Joe Despres jdespres@concentric.net sed -e 's/\(.\{80\}\).*/\1/' awk '{print substr($0,1,80);}' andru