delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2006/08/04/09:39:06

X-Spam-Check-By: sourceware.org
Date: Fri, 4 Aug 2006 09:38:56 -0400 (EDT)
From: Igor Peshansky <pechtcha AT cs DOT nyu DOT edu>
Reply-To: cygwin AT cygwin DOT com
To: Franz Wolfhagen <FRANZW AT dk DOT ibm DOT com>
cc: cygwin AT cygwin DOT com
Subject: Re: Escape Character
In-Reply-To: <OF7227ECD0.A2908835-ONC12571C0.0046C0E6-C12571C0.0046F2CA@dk.ibm.com>
Message-ID: <Pine.GSO.4.63.0608040936030.16540@access1.cims.nyu.edu>
References: <OF7227ECD0 DOT A2908835-ONC12571C0 DOT 0046C0E6-C12571C0 DOT 0046F2CA AT dk DOT ibm DOT com>
MIME-Version: 1.0
Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Unsubscribe: <mailto:cygwin-unsubscribe-archive-cygwin=delorie DOT com AT cygwin DOT com>
List-Subscribe: <mailto:cygwin-subscribe AT cygwin DOT com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-help AT cygwin DOT com>, <http://sourceware.org/ml/#faqs>
Sender: cygwin-owner AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
Delivered-To: mailing list cygwin AT cygwin DOT com

On Fri, 4 Aug 2006, Franz Wolfhagen wrote:

> cygwin-owner AT XXXXXX DOT XXX wrote on 04-08-2006 14:23:49:

<http://cygwin.com/acronyms/#PCYMTNQREAIYR>.  Thanks.

> > Hi
> >
> > I am new to Cygwin and I am just trying to use the escape character
> > example is
> >
> > echo "\t\t Hello"
> >
> > but this returns \t\t Hello and ignores the escape characters.
> >
> > I was looking for it to return Hello with a couple of TABS in front
> > like it does on our True64 unix system.  Is the escape character
> > differant in Cygwin or am I missing something ??? any help would be
> > great
>
> "man echo" has the answer - on Cygwin use the "-e" argument ie :  echo
> -e "\t\t Hello"

Almost correct, except that in bash, "echo" is a shell builtin, and you
should've been using "help echo" instead of "man echo".  Luckily, both
/bin/echo and bash's builtin understand the -e option.

It's usually a good idea to run "type COMMAND" first, to find out what
COMMAND is, to make sure you're looking at the right documentation.
	Igor
-- 
				http://cs.nyu.edu/~pechtcha/
      |\      _,,,---,,_	    pechtcha AT cs DOT nyu DOT edu | igor AT watson DOT ibm DOT com
ZZZzz /,`.-'`'    -.  ;-;;,_		Igor Peshansky, Ph.D. (name changed!)
     |,4-  ) )-,_. ,\ (  `'-'		old name: Igor Pechtchanski
    '---''(_/--'  `-'\_) fL	a.k.a JaguaR-R-R-r-r-r-.-.-.  Meow!

"Las! je suis sot... -Mais non, tu ne l'es pas, puisque tu t'en rends compte."
"But no -- you are no fool; you call yourself a fool, there's proof enough in
that!" -- Rostand, "Cyrano de Bergerac"

--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Problem reports:       http://cygwin.com/problems.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019