DO

DO <fspec> <argument list>

where <argument list> is a list of zero or more space-delimited textual tokens which are bound to the formal Arguments $0 through $9 referenced within the file identified by <fspec>.

The DO command forces fspec to be treated as a DO file (rather than a LIT or CMD file). This is useful in situations where the fspec in question exists in CMD and/or LIT variations as well as DO, since otherwise, the command search path would cause the CMD or LIT to be found first. It is also needed to force a file with an extension other than DO to be interpreted as a DO file (although it is not clear why you want to do that).

DO supports the command line argument ++fspec; for details see Arguments $0 through $9.

DO.LIT is invoked automatically by the command line processor if it determines that the specified file is a DO file, so it is not necessary to explicitly use "DO" except in the situations described above. DO.LIT is responsible for preprocessing the DO file to perform argument and macro substitutions.

MDO.LIT is identical to DO.LIT, but is referenced internally under different circumstances.

Comments

The maximum DO file size is approximately 122K. This is about the maximum size for a 430K partition, which is about the minimum partition needed for some other large LIT commands, such as SUBMIT. A-Shell will explicitly complain if the partition size is not sufficient.

When DO is used within a DO file to reference another DO file, the command line may contain references variables input during execution of the current DO file, $KBD0 thru $KBD9 (see K0 - K9 Commands), may contain upper and lower case functions (see Input Case), and may use the concentration operator $+ (see Concatenate Parameters).

History

2011 August, A-Shell 5.1.1227:  DO.LIT / MDO.LIT 2.1(124) and SUBMIT.LIT 3.1(150) now support file-based variable command line arguments using the ++fspec syntax.