If B4P is started with typed commands (from console command line, batch scripts, etc.) then command line switches can be provided which
influence the starting and execution behavior of the B4P interpreter.
Following rules apply:
Available command line switches
Swtich | Description |
---|---|
-c | Suppress all console specific features (use standard input instead of console input, no console control like cursor movement and colors). Use this switch for batch processing. |
-d | Normally, at start-up, B4P changes the working directory to the directory where the B4P program file to execute is located. This command line switch suppresses this and leaves the working directory unchanged. |
-i | (lower-case i) Start B4P and enter interactive mode immediately. Even if a B4P program has been specified, the program will not be loaded and started. |
-I | (upper-case i) MacOS / Linux only: Starty B4P in installation mode where the welcoming text and loading library files are skipped. Not recommended for regular B4P program use. The switch '-c' will also come effective here to suppress console features. |
-w | Suppress B4P welcome text. Attention 1: Also the license info text (e.g. demo mode only if no valid license exists) will be hidden. Attention 2: The B4P initialization program "B4P Init.b4p" will not be started. This file would otherwise load the default B4P library files (e.g. "Support Library"). The system variable runtime settings[verbose] is set to quiet. This feature is useful for batch scripts which shall run fast and not outputting unnecessary text. |
-q | Starts the B4P program with runtime settings[verbose]= quiet to suppress any unnecessary output. To suppress the welcome text, too, use teh command lie swtich -w, too. |
-x | Skip the "Press [Enter] to end the program" before B4P is exiting. Useful for running B4P programs from batch scripts without user interaction |
b4p -wx myprogram.b4p // All 5 variations are equivalent.
b4p myprogram.b4p -wx
b4p myprogram.b4p -xw
b4p -w -x myprogram.b4p
b4p myprogram.b4p -w -x