On 07 Sep 2002 23:28:29 +0200, Johan Svedberg wrote:
>
> I need some help. What I want to do is check if a program is on my
> system, and if it is I want to run it in my InitFunction. I'm guessing
> this could be done in a Function using PipeRead, but I have no idea how
> to do it... :-) Help would be greatly appriciated.
Do what you would do from a script or command line. Something like this:
Exec which myprogram >/dev/null 2>&1 && myprogram params
Some propretary unices (Solaris) have pretty unusable "which" that always
returns 0 and write errors on stdout. There are also "whereis" (external),
"where", "filetest -X" (tcsh/csh), "hash", "type" (sh).
Regards,
Mikhael.
--
Visit the official FVWM web page at <URL: http://www.fvwm.org/>.
To unsubscribe from the list, send "unsubscribe fvwm" in the body of a
message to majordomo_at_fvwm.org.
To report problems, send mail to fvwm-owner_at_fvwm.org.
Received on Sat Sep 07 2002 - 17:50:38 BST