User Command SETTINGS (Dyalog)
SETTINGS is a command used to set and get the various SALT settings.
SETTINGS is one of the SALT commands made into a user command.
The SALT environment uses a few global settings that are used while SALT is in function. Those settings are kept outside the workspace and restored at each new session.
This commands allows to report and change these settings either temporarily, during the session, or permanently so they are available again at the next session.
There are at the present time five different global settings SALT makes use of:
cmddir the list of Spice folders (commands) to use separated by ;, these are the folders where User Commands can be found. They are searched in the order given until the command is found.
compare the comparison program to use. When the command COMPARE (see UserCommands/SALT/Compare for details) is used this is the program used to compare the scripts. Default: APL, that is let APL do the comparison.
editor the editor program to use. When the command EXPLORE (see UserCommands/SALT/Explore for details) is used on a script this is the program used to edit the script.
edprompt editor confirmation prompt. When the command SAVE (see UserCommands/SALT/Save ford etails) is used it may need to confirm that you want to overwrite a file, etc. This skips that prompt if set to 1.
workdir the list of SALT storage folders to use separated by a semicolon, these are the folders where user scripts can be found. They are searched in the order given until the command is found.
SETTINGS will either display or set any of these settings. When setting the value returned is the effective value after the setting.
SETTINGS accepts a series of switches to alter its functionality:
-permanent will store the current setting(s) permanently in the registry so they are available at the next session
-reset will reload the current setting(s) from the registry
The settings cmddir and workdir are made up of several individual paths. There may be a time when you only want to add (or delete) a single path to the list. Instead of reentering the entire sequence of paths you can use , or ~ to add or delete paths.
For example, if your cmddir contains the paths \my\ucmds;\other\cmds and you do
]SETTINGS cmddir ~\my\ucmds
will result in \my\ucmds being removed from the list.
Note that if you remove all the paths SALT will nevertheless keep a minimal list to be able to function. SALT commands are always available whatever path you set.
]SETTINGS workdir \my\own\salt\folders;\and\some\other\ones -permanent ]SETTINGS compare ]SETTINGS -reset
This script is part of the Dyalog product. For that reason this page is immutable.
The script is version 1.0 from 2007