Short Description
This plugin allows to run javascript scripts from the command-line. It needs java 1.8 or higher to work. The script to run and its parameter are defined in the file job.xml in the home folder of icy. See the example job.xml and the example script in the jar. To run a script from the command-line provide a job.xml file and run the plugin from the command-line, for example with: java -jar icy.jar --headless --execute plugins.volker.commandlinescriptrunner.CommandLineScriptRunnerDocumentation
The plugin allows to run javascript scripts from the command-line.
Your script must contain a line
// PARAMETER START
and a line
// PARAMETER END
The plugin will define the variables for the input parameters and set the input values in this section. Note that everything between these two lines will be replaced when the script is run via the plugin. You can leave your own input parameter definitions in this section so that you can run the script from the script-editor as well.
The job.xml file must be in the icy-home folder. It must contain the name of the job, the path to the script-file and a list of parameters. For example:
<job title='Gaussian Blur Filter' type='script'>
<path>./scripts/gaussian_blur.js</path>
<parameter-list>
<parameter name="sigmaX">1.6</parameter>
<parameter name="sigmaY">1.6</parameter>
<parameter name="sigmaZ">1.6</parameter>
<parameter name="inputFolder">"/media/in/"</parameter>
<parameter name="outputFolder">"/media/out/"</parameter>
</parameter-list>
</job>
The list of parameters can be empty.