From owner-freebsd-questions@FreeBSD.ORG Sat Dec 31 02:10:11 2011 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 91798106566C for ; Sat, 31 Dec 2011 02:10:11 +0000 (UTC) (envelope-from erikt@midgard.homeip.net) Received: from ch-smtp05.sth.basefarm.net (ch-smtp05.sth.basefarm.net [80.76.153.6]) by mx1.freebsd.org (Postfix) with ESMTP id 0A7C88FC08 for ; Sat, 31 Dec 2011 02:10:10 +0000 (UTC) Received: from c83-255-51-20.bredband.comhem.se ([83.255.51.20]:28425 helo=falcon.midgard.homeip.net) by ch-smtp05.sth.basefarm.net with esmtp (Exim 4.76) (envelope-from ) id 1RgoBf-0000kx-Hq for freebsd-questions@freebsd.org; Sat, 31 Dec 2011 02:56:45 +0100 Received: (qmail 31994 invoked from network); 31 Dec 2011 02:56:40 +0100 Received: from owl.midgard.homeip.net (10.1.5.7) by falcon.midgard.homeip.net with ESMTP; 31 Dec 2011 02:56:40 +0100 Received: (qmail 38179 invoked by uid 1001); 31 Dec 2011 02:56:40 +0100 Date: Sat, 31 Dec 2011 02:56:40 +0100 From: Erik Trulsson To: Edward Martinez Message-ID: <20111231015640.GA38111@owl.midgard.homeip.net> References: <4EFE645B.8010906@gmail.com> <4EFE77D1.3090402@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <4EFE77D1.3090402@gmail.com> User-Agent: Mutt/1.5.21 (2010-09-15) X-Originating-IP: 83.255.51.20 X-Scan-Result: No virus found in message 1RgoBf-0000kx-Hq. X-Scan-Signature: ch-smtp05.sth.basefarm.net 1RgoBf-0000kx-Hq fee225b6ba4f1cf849098f588d7bb832 Cc: ??????? ???????? , FreeBSD Questions Subject: Re: why newline scape sequence does not work in Freebsd's bash X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 31 Dec 2011 02:10:11 -0000 On Fri, Dec 30, 2011 at 06:47:45PM -0800, Edward Martinez wrote: > On 12/30/11 17:06, ??????? ???????? wrote: > > I used ' singe quotes, so double quotes is: > > > > $ FRUIT_BASKET="apples oranges pears" > > $ echo -e "My fruit basket contains: \n $FRUIT_BASKET" > > My fruit basket contains: > > apples oranges pears > > > Thanks for the help, it worked. I find it interesting that FreeBSD's > echo man page does not mention the -e option is needed to > enable backslash escapes. I remembered why it worked on linux > is because i created an echo alias with the -e option. > So i will do the same for FreeBSD. The echo(1) manpage on FreeBSD doesn't say anything about '-e' because that version of echo doesn't have such an option. The echo you were actually using is the one builtin into bash and is described in the bash(1) manpage (including mention of the -e option.) -- Erik Trulsson ertr1013@student.uu.se