LISp-Miner Control Language Reference, version: 27.18.15 of 2 Mar 2022

LMExec Module

The LMExec module executes LMCL scripts. You have to download it separately from the LISp-Miner download page and extract it to the LISp-Miner root directory.

Afterwards, you can found the LMExec.exe file and launch it. It has a simple interface (see picture) to open a script, execute it and see its progress log.


LM Exec Main Window
You could open a script using the Open button in the top-right corner. You can press then the Start button in the bottom-left corner to execute it. After the execution of the script has finished, you can start it again using the same button.

If an error occurs during execution, you can switch to a text editor, change script at given position and save changes. You can press once again the Start button to run the updated version of the script, without a need to open the script again or even to restart the LM Exec module.

You can cancel a running script by the Cancel button. Be aware that this button functionality depends on the actual script code. It will not work if the script is stalled (eg. in an infite cycle).

You can also pause the execution, instead of outright cancelling the script. In this case you can export the log history (see later) and then re-start the script using again the Pause/Unpause button.

Execution log

The center space of the LM Exec windows occupies a text log describing execution of the script.

All the errors and warnings are logged and displayed during the script execution. So are the main Lua-script function calls and selected time-consuming LISp-Miner operations (depending on the log verbosity level).

If an error is encountered during the execution, the script is aborted and a description of error appears in the log together with the line-number on which this error had occurred. User-defined debug-messages could be logged using the log function (or its variants) from the lm namespace.

You can copy the whole log into clipboard by pressing the Copy log button. The log is also automatically saved into the <LM root>\Exec\_LMExec.log file.

Command line parameters

You can pass user-defined command line parameters to the LMCL script.

Each parameter has a syntax of /ScriptParam:<Name>=<Value>. Parameters are accessible from within the script using the lm.ScriptParam table followed by the parameter name.

Example:

LMExec.exe /Input:LMExec.Demo.Z.b.ScriptParam.lua /ScriptParam:FirstParam=Alfa /ScriptParam:SecondParam=2

lm.logInfo( "First parameter value is "..lm.ScriptParam.FirstParam);
lm.logInfo( "The second parameter value is "..lm.ScriptParam.SecondParam);