From: Jeff King Date: Fri, 14 Mar 2008 21:45:50 GMT Subject: Re: [PATCH] t/t6000lib.sh: tr portability fix fix Message-ID: <20080314214550.GA18326@coredump.intra.peff.net> In-Reply-To: <47DAED87.1000408@nrlssc.navy.mil> On Fri, Mar 14, 2008 at 04:26:31PM -0500, Brandon Casey wrote: > Here's the version with escaped dashes. If you do the sed version, it's > something to compare to for readability. > > [...] > > - '------------------------------' | > + '\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-' | Ugh. How about: sed 'yA~`!@#$%^&*()_+={}[]|\;:"<>,/? A------------------------------A' The 'A' delimiter is because in my test, Solaris sed didn't seem to understand \/ to include the literal '/'. And all of the other punctuation is already used in the pattern. ;) -Peff