www.delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin-developers/1998/03/02/19:08:11

From: cgf AT bbc DOT com (Christopher Faylor)
Subject: Re: @file
2 Mar 1998 19:08:11 -0800 :
Message-ID: <Ep8100.B7H.cygnus.cygwin32.developers@bbc.com>
References: <m13eh0fxzs DOT fsf AT creche DOT cygnus DOT com>
Reply-To: cgf AT bbc DOT com
To: cygwin32-developers AT cygnus DOT com

In article <3 DOT 0 DOT 5 DOT 32 DOT 19980302162624 DOT 00996230 AT pop DOT cygnus DOT com>,
Eric Bachalo  <ebachalo AT cygnus DOT com> wrote:
>>One last thing: be sure to define a quoting syntax for the contents of
>>the file.  It's important to be able to pass any command-line option,
>>including one containing spaces.
>
>Shouldn't the quoting syntax be identical to normal MS command line
>quoting?  I am assuming that this functionality would only be used in the
>command.com shell but I guess there is no reason not to use in a bash or
>ash, etc.
>
>I thought I would just push (insert) the file verbatim into the command
>line and into the function that separates out the individual args.  The
>only question I can think of now is how to deal with EOL in the file.  My
>first thought would be to replace them with a space before pushing.
>
>I was hoping to avoid path separator conversions, escape character stuff,
>etc. which would then force me to have an @FILE_MODE (as opposed to the
>MAKE_MODE) environment variable. :)

Actually, I think resorting to a file for this kind of thing is really
a bad idea.  If you use '@' you will have to make sure that it is quoted
appropriately for things that use it (mail programs, maybe?) and unquoted
in cygwin later on.  You will also inevitably have these files cluttering
up your /tmp area.

I think it would be far better to pass it in memory somehow either using
the mechanism I mentioned in spawn_guts, environment variables, or shared
memory.
-- 
http://www.bbc.com/	cgf AT bbc DOT com			"Strange how unreal
VMS=>UNIX Solutions	Boston Business Computing	 the real can be."

- Raw text -


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