delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/1997/11/25/17:34:03

From: tomas DOT fasth AT twinspot DOT net (Tomas Fasth)
Subject: Re: bash shell question
25 Nov 1997 17:34:03 -0800 :
Message-ID: <347AD95F.1598E823.cygnus.gnu-win32@twinspot.net>
References: <01BCF866 DOT 352EE670 AT ppp81 DOT cac DOT psu DOT edu>
Mime-Version: 1.0
To: Michael Zawacki <mjz115 AT psu DOT edu>
Cc: "'gnu-win32 AT cygnus DOT com'" <gnu-win32 AT cygnus DOT com>

Michael, you can fix your problem in at least two ways as I can see it.

One way is to quote the 'filename' variable expansion like this:
   ln -s "$filename"
The shell is passing arguments after having them processed by the usual
whitespace rule. By adding quotes the shell will treat it as a single
argument. In this case you should not have any quotes in the execs.txt
file, otherwise the quotes will be regarded as part of the path name.

The other way is to keep your quotes in the execs.txt file and instead
evaluate the ln command line. Like this:
   eval ln -s $filename
In this case, the shell is becoming aware of any quotes that exists in
the execs.txt file.

The result would be identical in both cases and should fix your problem.

Tomas
-
For help on using this list (especially unsubscribing), send a message to
"gnu-win32-request AT cygnus DOT com" with one line of text: "help".

- Raw text -


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