> -----Original Message----- > From: behapy [mailto:[EMAIL PROTECTED]] > Sent: Friday, January 24, 2003 4:04 AM > To: [EMAIL PROTECTED] > Subject: sed > > > Hi? > > kdjwiskjkdf+-www.kde.org+-333.kjkd.html > kdjfwiwji+-kbs.co.kr+-cgi-bin+-kkk.cgi > kdjfwiwji+-kbs.co.kr+-cgi-bin+-kk2.cgi > > => > > www.kde.org+-333.kjkd.html > kbs.co.kr+-cgi-bin+-kkk.cgi > kbs.co.kr+-cgi-bin+-kk2.cgi > > I'd like to remove the first words everyliles ~+- > > sed -e 's/^*+-//g' SOMEFILE.TXT don't work. > How do I do?
Try sed -e 's/^[^+]+\+-//' In english: Line starts with one or more not-pluses, followed by plus and minus. Since there is only one word to remove, using /g is probably not what you want. In addition '/^*' is meaningless: your asking for zero or more occurances of the start of a line. > Thanks, > GGG > NI Šujzª¶¶n¢Š²y~¹®Nn¢r²²–± -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]