Subject: FVWM: Starting xterms with -e

From: Jim Nicholson <[email-masked]>
Date: Mon, 5 Apr 1999 14:22:09 -0400 (EDT)

This is probably stupid, but I can't seem to figure out how to do this 
inside of fvwm2. I'm running 2.2.

>From inside an xterm, I can type 

xterm -bg black -fg green -e telnet foo.org

and it works, but

AddToMenu "Terms" "Sessions" Title
+ "osiris" Exec /usr/X11R6/bin/xterm -e /usr/bin/telnet foo.org

fails with no error. Or maybe one shows up, but it's inside the xterm
which is closing too fast to see it. 

If I change the above to

+ "osiris" Exec /usr/X11R6/bin/xterm -e /usr/bin/telnet

I get a telnet prompt.
--
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 [email-masked].
To report problems, send mail to [email-masked].

---

From: Dominik Vogt <[email-masked]>
Date: Mon, 5 Apr 1999 23:08:37 +0200

> xterm -bg black -fg green -e telnet foo.org

I can't believe this works. At least it doesn't for me and it
shouldn't. You have to quote the command after -e. Otherwise
xterm tries to interpret foo.org as a parameter, fails, prints
an error message and exits. The proper command line is:

  xterm -bg black -fg green -e 'telnet foo.org'

> which is closing too fast to see it. 

 + osiris Exec /usr/X11R6/bin/xterm -e '/usr/bin/telnet foo.org'

Bye

Dominik ^_^

--
Dominik Vogt, [email-masked]
Reply-To: [email-masked]
--
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 [email-masked].
To report problems, send mail to [email-masked].

---

From: Neil Bird <[email-masked]>
Date: Tue, 06 Apr 1999 10:32:47 +0100

>   xterm -bg black -fg green -e 'telnet foo.org'

  Ah. Does Jim then have a telnet 'default connection' environment
variable set up in his normal command-line state that's passed to the
xterm if issued from there, but not when issued from fvwm?

  That'd explain why it appears to work ...

-- 
========================- http://www.rrds.co.uk/ -======================
 Neil Bird                   |   This is who we are     The time is near
                             |        There are 270 days remaining
 mailto:[email-masked] |                           [ T-63 days! ]
--
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 [email-masked].
To report problems, send mail to [email-masked].

---

From: Brad Giaccio <[email-masked]>
Date: Tue, 6 Apr 1999 07:31:56 -0400

>   xterm -bg black -fg green -e 'telnet foo.org'

Well not to disagree but this works everytime for me 
AddToMenu OtherPlat "cosmo" Exec xterm -geometry 80x50 -T COSMO -e telnet cosmo.marymount.edu &

xterm(1)
-e program [ arguments ... ]
             This option specifies the program (and  its  command
             line  arguments)  to be run in the xterm window.  It
             also sets the window title and icon name to  be  the
             basename of the program being executed if neither -T
             nor -n are given on the command line.  This must  be
             the last option on the command line.

the reason it must be last is that the first arg after -e is the
executable and everything else is considered to be arguments for it.

My question would be what version of fvwm arge you using, I know this
works in 2.0.46, 2.2, and 2.3

-- 
--- There are two kinds of knowledge, you either know the answer or
			you know where to find it
		      -Kane, Johnson, and anonymous
--
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 [email-masked].
To report problems, send mail to [email-masked].

---

From: Ke Huang <[email-masked]>
Date: Tue, 6 Apr 1999 08:47:21 -0500 (CDT)

>  xterm -bg black -fg green -e 'telnet foo.org'

Actually, THIS doesn't work for me, and it shouldn't. If you run xterm
this way, xterm will try to execvp "telnet foo.org", literally. It will
then fail upon not finding the command "telnet foo.org". 

Of course, you may be using a smarter version of xterm than I. My version
is XFree86 3.3.3(88) .

As for the original poster, this is what I use in FvwmWharf in fvwm2 v2.2:

*FvwmWharf ant      Ant.xpm Exec exec rxvt -e telnet ant
                            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^

you can just replace rxvt with xterm and it should work.

--------
Ke Huang
Class of 2000 at Washington University
------------------------------------------
e-mail:  [email-masked]  (preferred)
         [email-masked]
         [email-masked]

---

From: Dominik Vogt <[email-masked]>
Date: Wed, 7 Apr 1999 00:35:36 +0200

> executable and everything else is considered to be arguments for it.

That's grey theory. On my system xterm requires the argument after
-e to be quoted, no matter if I run it from a shell or from my
config file. It complains about 'foo.org' not being understood
as a command line option to xterm. No matter what, it's not a
fvwm bug.

Bye

Dominik ^_^