[A83] Re: ifdef 83p
[Prev][Next][Index][Thread]
[A83] Re: ifdef 83p
> Van: Dan Weiss <dwedit@hotmail.com>
And now for the people who never used DOS:
> echo #define TI83P >temp.z80
Creates a file called temp.z80 with the text "#define TI83P"
> echo #define ION >>temp.z80
Appends (adds) the text "#define ION" at the end of temp.z80
> if exist %1.z80 type %1.z80 >>temp.z80
> if exist %1.asm type %1.asm >>temp.z80
%1 is the first argument you gave to your batch-file (so when you typed
"asm.bat blah", then %1 = "blah"). Further arguments can be found in %2,
%3, ..,%9
While the 'echo'-command is to output a string inside your batch-file, you
use 'type' to output a file, the '>>' directive means that it should be
appended to the file mentioned next. Otherwise it would go to the screen
(DOS-box).
The two lines above check if such a file (%1) with the extension *.z80 or
*.asm exists and then appends that file to our temp.z80
Now you only need some commands to assemble temp.z80 and to create %1.8xp
(*might* do some cleanup too)
Henk Poley