Created
October 10, 2016 22:18
-
-
Save unforswearing/ca87127c3b1d4abdaa47ec325b9351d3 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
set _Path to "<<enter path to your script folder here>>" | |
set scriptLaunch to text returned of (display dialog "Enter name of script to run" default answer "" buttons "OK" default button "OK") | |
if scriptLaunch contains "" then | |
error number -128 | |
else if scriptLaunch contains scriptLaunch then | |
try | |
set scriptRun to _Path & "/" & scriptLaunch & ".scpt" | |
run script scriptRun | |
on error | |
display alert "Your script failed to launch." | |
end try | |
end if |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I really like your idea here but I've thought of better solution so I rewrote it to support a 'choose a file from folder' prompt.
Now you only need to use the arrows + return to run a script :)
You can check my gist here, tell me what you think.