Category : Communication (modem) tools and utilities
Archive   : WDMP0210.ZIP
Filename : PARSECMD.TXT
This text explains then method I use in my programs to parse the
program input parameters.
If there is only a ? given then a command summary is displayed.
The Parameters are compiled from three sources:
1. An evironment varible the same as the program name.
2. An ASCII file[s].
3. The command tail.
If the evironment variable begins with a + it is appended to the
command tail otherwise it is prepended. The result is then parsed.
If a parm file specification is incountered, (beginning with an @),
then the file contents are inserted into the command string in place
of the @ parameter. There can be multiple parm files used.
Strings can be enclosed with single (') or double (") quotes.
Either quote can be entered by enclosing it in the other. ("'")
Two consecutive switch characters will change the switch to the
next character. Example: sw is / then //- changes it to -.
Parameters which do not begin with the switch character are
counted and used in rotation. For example if the program accepts 2
non-switch parameters and the input is 'abc def ghi', then the result
would be the same as 'ghi def'.
EXAMPLES
GIVEN:
Program accepts 2 filenames and toggle switches.
File PARMA contains:
Filea /D
/Q
File PARMB contains:
Filed /e
Environment variable:
PROGNAME=/K FILEB
THEN:
Command line: PROGNAME filex /x
Would give : PROGNAME fileb filex /x /k
Command line: PROGNAME filex @parma /k
Would give : PROGNAME filea filex /d /q
Command line: PROGNAME @parma filex
Would give : PROGNAME filex filea /k /d /q
Command line: PROGNAME @parma @parmb
Would give : PROGNAME filed filea /k /d /q /e
Very nice! Thank you for this wonderful archive. I wonder why I found it only now. Long live the BBS file archives!
This is so awesome! 😀 I’d be cool if you could download an entire archive of this at once, though.
But one thing that puzzles me is the “mtswslnkmcjklsdlsbdmMICROSOFT” string. There is an article about it here. It is definitely worth a read: http://www.os2museum.com/wp/mtswslnk/