Time stamp VERS:- 00.02 DATE:- 07/31/82 TIME:- 22:13:09 ************************************************************* * * QUICK OVERVIEW: Increment version and insert current date * =============== and time for each assembly or edit run. * ************************************************************* ************************************************************* * * File Tracking Program * by Eric Forbes * c/o Mississauga, Ont. Canada RCP/M System * (416) 826-5394 * ************************************************************* Copyright (c) 1982, E. Forbes; permission granted to use, copy and distribute for non-commercial purposes. This program may be assembled to run as a stand alone COM file or it may be added to an assembler so that each time a file is edited or assembled the version number will be incremented and the current date and time will be inserted into the first record of the file. This program loads the 1st record from a file and then looks for 'VERS:- ', 'DATE:- ' and 'TIME:- ' When it finds any of the three it will update ONLY that data. Each entry MUST be exactly as shown, upper case characters, colon, minus and space all with the high bit off. After updating, it writes the modified record back to disk, to the same place, restores the patched jump in the assembler / editor, decrements the character count in the command line tail (80h) if an option was used and jumps to the assembler / editor. The command line and fcbs remain unchanged to ensure normal operation of the assembler/editor. When creating a new text file insert 'VERS:- 00.00' and this program will increment the minor number each time you run it If the option 'm' is used, the major number will be incre- mented and the minor zeroed. If the 'n' option is used, the version number will be unchanged. 'M' and 'N' are mutually exclusive. To use the 'DATE:- ' and 'TIME:- ' functions, this program expects to find three consecutive bytes at MONTH and HOUR, in BCD format. E.G. to print the date 07/31/82, the bytes 07H 31H 82H should be available at HOUR, HOUR+1 and HOUR+2 If you do not have a clock ignore the 'month' and 'hour' equates. They are both read only and will only be read if 'DATE:- ' or 'TIME:- ' is found in the 1st record of the file. As a part of the 'TITLE' line each page of a listing will be time stamped. Don't forget enough spaces after time and date For ported or external clocks, a routine at the begining would not be beyond the realms of possisbilty. The program may be assembled to run stand alone, but a far better use, is to patch it to the end of your assembler. I chose the high memory end of the assembler as only one address needs to be changed and after it's done it's thing the assembler will use the space for normal data etc. ORG this program to an address at the end of your assembler, assemble it to a COM file and load it using DDT or equivalent, next load your assembler.COM in front of this program. Then change a jump at the begining of the assembler to the ORG value. Save the whole shmozzle as a COM file and you will have no further trouble deciding which file/listing is current. This addition is completely 'invisable' to the assembler and uses no memory space as it is loaded with the assembler in it's work area. Command examples: ================= a:timestmp b:xyz.rel,lst:=c:xyz.mac m get this prog. on A, put object on B, prn to printer, source found on C and this is a major version change. timestmp =xyz increment minor version number, date & time stamp. assemble xyz.mac, create xyz.rel, all on the default disk. timestmp =xyz n as above, but leave version number unchanged. timestmp =xyz m n INVALID (only 1 option allowed) timestmp xyz m leave out '=' if stand alone Source file extention will always default to 'MAC' ****************************************************** * * * May you never again have six " CURRENT " files ! * * * ****************************************************** Eric.