delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2006/04/28/00:54:28

X-Spam-Check-By: sourceware.org
Message-ID: <20060428045411.44427.qmail@web38909.mail.mud.yahoo.com>
Date: Thu, 27 Apr 2006 21:54:11 -0700 (PDT)
From: Siddhartha Shivshankar <s_siddhartha AT yahoo DOT com>
Subject: Re: Variable read error? Multiple spaces
To: cygwin AT cygwin DOT com
MIME-Version: 1.0
Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
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

Thanks Chris, Eric, quoting the variable worked.

Eric Blake <ebb9 at byu dot net> writes:

>It is an error on your part for not quoting properly.  But this
>is not cygwin-specific, so I would advise getting a good
>tutorial on shell programming and reading it (the web has  
>plenty of resources, google is your friend).   

I use Mendel Cooper's Advanced Bash-Scripting Guide. In the    
following link, there is a discussion of the $IFS internal field
 
separator variable specific to echo and linefeeds. In general,  
I suppose that any command could replace echo and any $IFS    
characters (multiple spaces in my example) could replace
linefeeds.
 
http://www.tldp.org/LDP/abs/html/internal.html#ECHOREF

>POSIX states that $() command substitutions that consist solely
of
>redirections produce unspecified results, and are thus
non-portable.

Thank you. The following page from the scripting guide has a    

link to a Bash FAQ. The FAQ apparently has a complete listing   
of bash features that the traditional Bourne shell lacks.   

http://www.tldp.org/LDP/abs/html/portabilityissues.html

The following page from the same guide lists command
interpreters    
and provides a Note that links to the POSIX specifications.

http://www.tldp.org/LDP/abs/html/sha-bang.html

-Siddhartha.



__________________________________________________
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com 

--
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