Jelena Mamčenko Operating Systems Lecture Notes on Operating Systems 42This file sets the PATH, defines a prompt and a temporary directory, runs a utility program and then clears the screen and types a menu. Batch Sample #1 Here is a sample batch file you might use to periodically back up and clear a word processing data disk. It assumes that word processing backup files are named with extension .BAK, you don't want them, and they are on the disk in drive B:. The batch file is called BAK.BAT and is also on the word processing data disk in drive B:. Start it by typing B:BAK. @ECHO OFF CLS ECHO * * * Word processing cleanup * * * ECHO Put backup disk in drive A: PAUSE ERASE B:*.BAK COPY B:*.* A: DEL A:BAK.BAT ECHO Backup is complete. Label your disk. The first line turns screen echo off. The next line clears the screen. A label is then displayed with instructions on where to place the backup disk. A keypress needed to continue, then all .BAK files are erased and all files on drive B: are copied to A:. The batch file is then deleted from A: and
This is the end of the preview.
access the rest of the document.