Hi Jeremy, while you are at it:
Wondering how Jerome could test whether the current shell
is FreeCOM without needing temp files, I found out that
half of the SET options are not yet listed in SET /? help.
The currently available actual options of SET would be:
SET test=one results in TEST=one
SET /C test=one results in test=one (keep case of variable name)
SET /U test=one results in TEST=ONE (uppercase variable value)
SET /P test=one shows "one:" as prompt, TEST = user entered value
SET /E test=one runs command "one", uses 1st returned line as value
SET /I displays information about environment size and memory usage
Note that SET /E requires a temp file, so it has the same
problem as pipelines: It only works with writeable temp dir.
You usually want to add a space after the prompt, for example:
"SET /P test=please enter a value " with " " after "value".
Also note that while SET /E test=vol sets TEST to the message
which VOL produces about your volume label (which will depend
on which language your FreeCOM has) you cannot SET /E test=ver
because VER always first displays one EMPTY line before starting
to show version information, so it behaves like "SET test=" and
deletes the varible TEST instead of setting it to anything ;-)
Maybe you could update the help messages. Thanks!
Do you have suggestions for easy, temp-file-free detection of
FreeCOM in BAT which works even with older versions of FreeCOM?
Regards, Eric
___
Freedos-user mailing list
Freedos-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/freedos-user