Re: function oddity

2007-07-12 Thread Dominik Vogt
On Thu, Jul 12, 2007 at 10:16:32AM +0200, Viktor Griph wrote:
> On Thu, 12 Jul 2007, Dominik Vogt wrote:
> 
> >On Thu, Jul 12, 2007 at 03:41:38PM +1000, Scott Smedley wrote:
> >>I need confirmation I'm not crazy.
> >>
> >>This works ok (substitute rxvt for xterm if appropriate):
> >>
> >>AddToFunc fn I Exec exec rxvt $*
> >>fn -e sleep 4
> >>
> >>this is ok too:
> >>
> >>AddToFunc fn3 I Test (x rxvt) Exec exec rxvt $*
> >>fn3 -e sleep 4
> >>
> >>but this isn't:
> >>
> >>AddToFunc fn2
> >>Test (x rxvt) + I Exec exec rxvt $*
> >>fn2 -e sleep 4
> >
> >The Test command expands the $* when it is executed.  Try
> >
> > Test (x rxvt) + I Exec exec rxvt $$*
> > 
> >
> 
> It is also possible to use
> 
>- Test (x xterm)  + I Exec exec xterm $*
>   ^^^

By the way, with my latest commit you can say

  EchoFuncDefinition fn2
-->
  [FVWM][EchoFuncDefinition]: definition of function 'fn2':
  [FVWM][EchoFuncDefinition]:   i exec exec rxvt


You can immediately see what has happened.

Ciao

Dominik ^_^  ^_^

 --
Dominik Vogt, dominik.vogt (at) gmx.de


signature.asc
Description: Digital signature


Re: function oddity

2007-07-12 Thread Viktor Griph

On Thu, 12 Jul 2007, Dominik Vogt wrote:


On Thu, Jul 12, 2007 at 03:41:38PM +1000, Scott Smedley wrote:

I need confirmation I'm not crazy.

This works ok (substitute rxvt for xterm if appropriate):

AddToFunc fn I Exec exec rxvt $*
fn -e sleep 4

this is ok too:

AddToFunc fn3 I Test (x rxvt) Exec exec rxvt $*
fn3 -e sleep 4

but this isn't:

AddToFunc fn2
Test (x rxvt) + I Exec exec rxvt $*
fn2 -e sleep 4


The Test command expands the $* when it is executed.  Try

 Test (x rxvt) + I Exec exec rxvt $$*
 



It is also possible to use

   - Test (x xterm)  + I Exec exec xterm $*
  ^^^

/Viktor



Re: function oddity

2007-07-12 Thread Dominik Vogt
On Thu, Jul 12, 2007 at 03:41:38PM +1000, Scott Smedley wrote:
> I need confirmation I'm not crazy.
> 
> This works ok (substitute rxvt for xterm if appropriate):
> 
> AddToFunc fn I Exec exec rxvt $*
> fn -e sleep 4
> 
> this is ok too:
> 
> AddToFunc fn3 I Test (x rxvt) Exec exec rxvt $*
> fn3 -e sleep 4
> 
> but this isn't:
> 
> AddToFunc fn2
> Test (x rxvt) + I Exec exec rxvt $*
> fn2 -e sleep 4

The Test command expands the $* when it is executed.  Try

  Test (x rxvt) + I Exec exec rxvt $$*
  

> (it starts up an interactive shell, instead of sleeping & exiting)
> 
> Am I missing something? or am I going to have to use the source?

Ciao

Dominik ^_^  ^_^

 --
Dominik Vogt, dominik.vogt (at) gmx.de


signature.asc
Description: Digital signature


function oddity

2007-07-11 Thread Scott Smedley
Hi all,

I need confirmation I'm not crazy.

This works ok (substitute rxvt for xterm if appropriate):

AddToFunc fn I Exec exec rxvt $*
fn -e sleep 4

this is ok too:

AddToFunc fn3 I Test (x rxvt) Exec exec rxvt $*
fn3 -e sleep 4

but this isn't:

AddToFunc fn2
Test (x rxvt) + I Exec exec rxvt $*
fn2 -e sleep 4

(it starts up an interactive shell, instead of sleeping & exiting)

Am I missing something? or am I going to have to use the source?

Scott.