This is the mail archive of the cygwin mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Variable read error? Multiple spaces


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/


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]