Working with a local terminal window

I would like to open a terminal window on my eggplant mac machine and interact with it. Can I do this with eggplant and if so how?

Thank you in advance
Tom

If you mean that you’d like your Eggplant script to be able to execute terminal commands, that’s easy to do using the shell command/function. For example:

put shell("ls")

For more complex situations, take a look at the open process, write to process, read from process, and close process commands in Chapter 14 of the SenseTalk Reference manual.

If that isn’t what you’re looking for, please describe your situation in more detail.

We have used open process to telnet to a remote machine and start the vnc server and continue on in the script to connect. In some case this works fine but in others once the opened process handle is closed the vnc windows turns grey. As an alternative we have found the if we open a terminal window locally on the mac and restart the remote vncserver the vncviewer remains visable. We are just looking to automate that terminal interaction.

[quote=“SenseTalkDoug”]If you mean that you’d like your Eggplant script to be able to execute terminal commands, that’s easy to do using the shell command/function. For example:

put shell("ls")

For more complex situations, take a look at the open process, write to process, read from process, and close process commands in Chapter 14 of the SenseTalk Reference manual.

If that isn’t what you’re looking for, please describe your situation in more detail.[/quote]

Okay, in that case you may want to try using AppleScript to tell Terminal to run your command, something like this:

do AppleScript {{
tell application "Terminal"
  do script "ls -l" -- put your telnet command here instead of "ls -l"
end tell
}}

I think that will do what you want.