[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: possible sed bug

From: Paul Jarc
Subject: Re: possible sed bug
Date: Sun, 14 Oct 2001 17:21:44 -0400
User-agent: Gnus/5.090004 (Oort Gnus v0.04) Emacs/20.7

"Chris Cowsley" <address@hidden> wrote:
> text=mystuffhere
> echo $text
> date +%Y.%m.%d\ %a\ %X\ . | sed s/\ ./\ $text/
> date +%Y.%m.%d\ %a\ %X\ . | sed s/\ \./\ $text/
> date +%Y.%m.%d\ %a\ %X\ . | sed "s/ ./ $text/"

date +%Y.%m.%d\ %a\ %X\ . | sed 's/ \./ $text/'

The "." needs to be backslash-escaped, but sh will strip the backslash
if it isn't either quoted or itself escaped with another backslash.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]