From: cpurvis3 on
I can ...
> exec dtterm -title "mytitle" -e "ls -la"

but in doing so the new shell closes when the cmd is completed plus it
closes the the calling shell!

If I ...
> eval dtterm -title "mytitle" -e "ls -la" , at least the calling shell doesn't close.

Is there a way to keep the new shell open after the cmd is finished?

From: cpurvis3 on
On May 1, 11:55 pm, cpurv...(a)csc.com wrote:

Basically I want to be able to open term window (from my application)
and execute some cmd. But, I want the term window to remain open so
user can interact with it.
[using ksh in solaris environment]

From: Barry Margolin on
In article <1178078137.125204.13140(a)h2g2000hsg.googlegroups.com>,
cpurvis3(a)csc.com wrote:

> I can ...
> > exec dtterm -title "mytitle" -e "ls -la"
>
> but in doing so the new shell closes when the cmd is completed plus it
> closes the the calling shell!
>
> If I ...
> > eval dtterm -title "mytitle" -e "ls -la" , at least the calling shell
> > doesn't close.
>
> Is there a way to keep the new shell open after the cmd is finished?

dtterm -e "ls -la; read"

will wait for the user to press Return before the window closes.

If you want them to be dropped into an interactive shell, you could do:

dtterm -e "ls -la; $SHELL"

--
Barry Margolin, barmar(a)alum.mit.edu
Arlington, MA
*** PLEASE post questions in newsgroups, not directly to me ***
*** PLEASE don't copy me on replies, I'll read them in the group ***
From: Barry Margolin on
In article <1178078508.306848.202260(a)y80g2000hsf.googlegroups.com>,
cpurvis3(a)csc.com wrote:

> On May 1, 11:55 pm, cpurv...(a)csc.com wrote:
>
> Basically I want to be able to open term window (from my application)
> and execute some cmd. But, I want the term window to remain open so
> user can interact with it.
> [using ksh in solaris environment]

Doesn't the second solution I posted do that?

--
Barry Margolin, barmar(a)alum.mit.edu
Arlington, MA
*** PLEASE post questions in newsgroups, not directly to me ***
*** PLEASE don't copy me on replies, I'll read them in the group ***
From: cpurvis3 on
close ... I need to run with the following (insert the shell cmd after
the "-e"):

> dtterm -e ksh "ls -la;ksh"

or ...

> dtterm -e ksh "ls -la;read"