Maybe put in quotes? 

On Thu, Jun 22, 2023, at 10:07 AM, Bret Johnson wrote:
>> Hi fellow users :-)
>>
>> I have been wondering which chars are special in SET
>> in FreeCOM and whether they can be escaped or similar.
>
> I don't know specifically about FreeCOM, but I know in some versions of 
> DOS an environment variable can't contain an equals sign.  For example, 
> in some DOS versions you can't do this while in others you can:
>
>   SET ParameterList=Var1=1,Var2=2
>
> This has caused me some grief in the past when I try to allow the user 
> to enter option parameters either from the command-line or from an 
> environment variable.  For example, if the program I'm trying to run is 
> called PROGRAM I allow the user to set an environment variable named 
> PROGRAM that contains the "default" command-line parameters:
>
>   SET PROGRAM=Option1=Yes, Option2=No
>
> I want that to work the same way as if the user had done this:
>
>   PROGRAM Option1=Yes, Option2=No
>
> Sometimes it works and sometimes it doesn't, depending on which version 
> of DOS I am using.  And I'm not even sure it is consistent across all 
> different DOS versions from the same manufacturer.  BTW, the way I get 
> around this problem is to allow the user to either enter an equals (=) 
> or a colon (:) as the separator character and explain the situation in 
> the documentation..
>
> The reason I bring this up is that in a recent post there was some 
> discussion over whether or not FreeDOS should fix all the bugs in 
> MS-DOS (essentially, improving MS-DOS) or duplicate the bugs, and the 
> consensus seemed to be to duplicate the bugs.  I don't know if allowing 
> an equals sign in an environment variable would be considered a bug or 
> a feature, but I would classify it as a bug, and I don't remember 
> specifically how MS-DOS handles it.
>
>
> _______________________________________________
> Freedos-user mailing list
> Freedos-user@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/freedos-user


_______________________________________________
Freedos-user mailing list
Freedos-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/freedos-user

Reply via email to