next up previous contents
Next: If statements and jumps Up: Command Files Previous: Passing parameters to scripts

Silence is sometimes golden

If you build up a collection of scripts which call scripts which call scripts, you'll probably get sick of watching every line go by. Moreover, in many cases it actually takes Macaulay longer to get the results up on the screen than to think them up. By the command ``incr-set prlevel 1'' at the beginning of a sequence of commands, and ``incr-set prlevel -1'' at the end, you can normally hide from your sight everything that happens in between, and speed up the process to boot. Many people like to do this at the beginning and end of all of their scripts, so that their scripts run almost like built-in Macaulay commands.

Exceptions: Error messages will still be printed. What you have actually done is to increment and decrement a Macaulay set variable which starts out with value 0, and which inhibits output to the screen whenever it is positive. Thus, if you first enter ``set prlevel -3'' then your first three voices of ``silent'' scripts will show their output after all, and any higher voice silent scripts will in fact run silently.



Sorin Popescu
Fri Feb 14 17:37:19 EST 1997