From owner-freebsd-questions Tue Dec 3 2:42:16 2002 Delivered-To: freebsd-questions@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id BDD4B37B401 for ; Tue, 3 Dec 2002 02:42:14 -0800 (PST) Received: from grillolja.cs.umu.se (grillolja.cs.umu.se [130.239.40.17]) by mx1.FreeBSD.org (Postfix) with ESMTP id 0567943EBE for ; Tue, 3 Dec 2002 02:42:14 -0800 (PST) (envelope-from tdv94ped@cs.umu.se) Received: from localhost (localhost [127.0.0.1]) by amavisd-new (Postfix) with ESMTP id A808AA017; Tue, 3 Dec 2002 11:42:07 +0100 (MET) Received: from kvist.cs.umu.se (kvist.cs.umu.se [130.239.40.192]) (using TLSv1 with cipher EDH-RSA-DES-CBC3-SHA (168/168 bits)) (No client certificate requested) by grillolja.cs.umu.se (Postfix) with ESMTP id D6AA9A00A; Tue, 3 Dec 2002 11:42:05 +0100 (MET) Date: Tue, 3 Dec 2002 11:42:05 +0100 (MET) From: Paul Everlund To: Roman Neuhauser Cc: Malik =?iso-8859-2?Q?B=FClent?= , Subject: Re: is there a "replace command" ? In-Reply-To: <20021203103346.GG56031@freepuppy.bellavista.cz> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=iso-8859-1 Content-Transfer-Encoding: 8BIT X-Virus-Scanned: by amavisd-new amavisd-new-20020630 Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Tue, 3 Dec 2002, Roman Neuhauser wrote: > # tdv94ped@cs.umu.se / 2002-12-03 11:13:39 +0100: > > On Tue, 3 Dec 2002, Malik Bülent wrote: > > > But my expression has "/" that is there is a "/" in a expression > > > What shall i do ? > > > my expression is "new: 11" I want to change "new: 11" with "new/11" > > > > > > thanks > > > > # echo "new: 11" | sed s/new\:\ 11/new\\/11/ > > you don't have to use slashes for the delimiters. see sed(1). > > roman@freepuppy ~ 1003:0 > echo "new: 11" | sed 's,: ,/,' > new/11 > roman@freepuppy ~ 1004:0 > echo "new: 11" | sed 's:\: :/:' > new/11 > roman@freepuppy ~ 1005:0 > echo "new: 11" | sed 's-: -/-' > new/11 Thanks for the tip! I wasn't aware of that. When it comes to man sed(1): Reading a Kafka book is light weight reading compared to that man page. :-) Best regards, Paul To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message