Create an icon to begin a script?

JRF

Member
Feb 1, 2014
5
0
Hi, all. I am trying to find a way to put some sort of icon on my PI workspace that begins a script. I have put my most used process icons into the workspace, but have yet to figure out how to do a similar thing for scripts. Weary of having to sort through the scripts directory every time I need one! Any help appreciated. Thanks.

JRF
 

pfile

PTeam Member
Nov 23, 2009
5,625
105
if the script in question has a little triangle at the lower left of the script UI, you can drag the triangle to the desktop. this will create a process icon which references the script and saves how it was configured at the moment you dragged the triangle. if you double-click that process icon, it will open a process called "Script", which is kind of a bridge between processes and script. pushing the round button (global apply) will start the script with all the arguments contained in the script process.

if the script does not have a little triangle, you can still bring up the Script process, reset it, clear the MD5 sum, and then use the file folder button to navigate to the location of the script. (src/scripts/, inside of the folder where pixinsight is installed, which differs by operating system.)

or you can use the $PXI_SRCDIR variable, for instance:

$PXI_SRCDIR/scripts/FFTRegistration/FFTRegistration.js

so that you don't have to worry about the exact path to where PI is installed.

rob