I wrote a shell script that opens a file in an editor (Emacs) using the shell command 'emacsclient'. It works fine from the command line, but doesn't do anything when I execute it in KM via the "Execute Shell Script" action. From the command line it opens a file or folder in Emacs instantly, but from KM It just silently does nothing.
I verified that other shell scripts work in KM, doing simple things like 'echo' and 'pwd'.
Why would this particular script behave differently in KM?
Update. It works now, sort of. I needed to give the full path to my script. I guess the environment that KM runs it in does not have the same PATH as my terminal
But now I want to change it a little. I want to run a shell script as a "text script" (one of the options KM gives in the Execute Shell Script action") and I want to insert the value of a variable, perhaps %SystemClipboard% or other things, into the script. I noticed that my only option is typing text into that box, and it doesn't interpolate tokens. Is there any way to do this?