Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Re: Can I do without "eval" here?



    Hi Michal :)

 * Michal Politowski <mpol@xxxxxxxxxxxxxxxxxxx> dixit:
> On Tue, 14 Mar 2006 10:16:19 +0100, DervishD wrote:
> >     options=("-x")
> >     (($#)) && options=("-y" "$1")
> >     CMD $options[1] $options[2] foo
> 
> There is no need to split the array manually.
> CMD $options foo
> will do.

    Oops, my bad O:)) At first I didn't write the solution using an
array, and afterwards I just forgot that arrays don't need manual
splitting. Thanks for pointing :)

    Raúl Núñez de Arenas Coronado

-- 
Linux Registered User 88736 | http://www.dervishd.net
http://www.pleyades.net & http://www.gotesdelluna.net
It's my PC and I'll cry if I want to... RAmen!



Messages sorted by: Reverse Date, Date, Thread, Author