user2174771
user2174771

Reputation: 7

How can I run a command in a remote xterm?

In a cshell script, I spin-out an xterm. From the shell where the script is executed from, I wish to execute a command (eg: banner master win) in the xterm that has been spun out from the script.

Can you suggest me a way to do that?

Do you think finding for xterm's paid would help me in this case?

Upvotes: 0

Views: 1049

Answers (1)

Gagravarr
Gagravarr

Reputation: 48376

Just use the -e argument to the xterm when you start it

From the output of xterm --help

[-e command args ...]

So running the following will launch an xterm to run the watch command against the date program, with a suitable title:

xterm -T "Date" -e watch date &

Upvotes: 1

Related Questions