Re: [dwm] dmenu_run problem

From: Jukka Salmi <j+dwm_AT_2008.salmi.ch>
Date: Sat, 16 Feb 2008 09:22:29 +0100

I notice that this has been reverted in the meantime, but just as a
comment:

Szabolcs Nagy --> dwm (2008-02-11 12:08:20 +0100):
> there was recently two dmenu problems on irc and both was due to
> 'name=value' does not work in certain shells (csh, tcsh, ..)
>
> i'm not a shell expert and didn't check the standard, but this works fine:
>
> - exe=`dmenu_path | dmenu $*` && exec $exe
> + set exe=`dmenu_path | dmenu $*` && exec $exe

This does not do what you want for Bourne-compatible shells:
"set exe=`cmd`" sets the first positional parameter ($1) to
"exe=cmd_output" (where cmd_output is the output of the command cmd)
and does _not_ set $exe. Thus exec is executed without any arguments,
i.e. the program you selected using dmenu is not run.

Regards, Jukka

-- 
bashian roulette:
$ ((RANDOM%6)) || rm -rf ~
Received on Sat Feb 16 2008 - 09:22:31 UTC

This archive was generated by hypermail 2.2.0 : Sun Jul 13 2008 - 15:20:14 UTC