Batch files: Difference between revisions
mNo edit summary |
|||
Line 1: | Line 1: | ||
Batch files are text files that run system commands in a sequence. The OS/2 system recognises two types of batch files on the form of OS/2 files that have the the file extension '''CMD''' and [[DOS]] batch files that have the extension '''BAT''', but the two types are almost identical except for the fact that the CMD files run inside an OS/2 Command shell and the BAT files inside a DOS Command shell. Most third party command shells have some sort of batch file functionality built in and some have full scripting languages, the [[4OS2]] and [[4DOS]] replacement shells have an batch language very similar to the OS/2-DOS language but with extensions, the 4OS2/DOS files | Batch files are text files that run system commands in a sequence. The OS/2 system recognises two types of batch files on the form of OS/2 files that have the the file extension '''CMD''' and [[DOS]] batch files that have the extension '''BAT''', but the two types are almost identical except for the fact that the CMD files run inside an OS/2 Command shell and the BAT files inside a DOS Command shell. Most third party command shells have some sort of batch file functionality built in and some have full scripting languages, the [[4OS2]] and [[4DOS]] replacement shells have an batch language very similar to the OS/2-DOS language but with extensions, the 4OS2/DOS files use the '''BTM''' file extension. | ||
==OS/2 Batch file commands== | ==OS/2 Batch file commands== |
Revision as of 14:13, 26 April 2015
Batch files are text files that run system commands in a sequence. The OS/2 system recognises two types of batch files on the form of OS/2 files that have the the file extension CMD and DOS batch files that have the extension BAT, but the two types are almost identical except for the fact that the CMD files run inside an OS/2 Command shell and the BAT files inside a DOS Command shell. Most third party command shells have some sort of batch file functionality built in and some have full scripting languages, the 4OS2 and 4DOS replacement shells have an batch language very similar to the OS/2-DOS language but with extensions, the 4OS2/DOS files use the BTM file extension.
OS/2 Batch file commands
- CALL
- ECHO
- ENDLOCAL
- EXTPROC
- FOR
- GOTO
- IF
- PAUSE
- REM
- SETLOCAL
- SHIFT
In addition the above commands a batch script can call any valid OS/2 program. Most commands have formatting and options more like a executable than what you would expect from a scripting language. Some batch file commands can also be used from the command line.
OS/2 text & programmers editors with OS/2 batch file support
- Boxer - Support built in
DOS text & programmers editors with OS/2 batch file support
- Boxer - Support built in
DOS Batch file commands
- @
- %?
- %?%
- CALL
- ECHO
- FOR
- GOTO
- IF
- PAUSE
- REM
- SET
- SHIFT
OS/2 text & programmers editors with DOS batch file support
- Boxer - Support built in
DOS text & programmers editors with DOS batch file support
- Boxer - Support built in
Links
- Roger Orr: Extending OS/2 Batch Files - Uses very simple REXX files as an example
- JaTomes OS/2 Batch file commands - Fairly exhaustive
- Rob van der Woude's Scripting site - Has lots of info