Sunday, November 19, 2017

#1 2017-09-21 01:30:58 pm

artphotodude
Member
Registered: 2012-10-15
Posts: 45

Keystroking to Terminal Application...

Question 1 (Important One) While most of the time when you are dealing with Terminal in Applescript, you are doing "one-liners" into and out of a Terminal process, what would be the way to keystroke into (or tell the terminal window) to keystroke in inputs? 

In other words, how do I tell an exiting Terminal window with a specific name to do followup script commands once it is open and running?

I have a terminal app that I use a lot that I want to GUI to make more user friendly. 



Question 2 (Nice, but not Critical) Is there a way to force a terminal app that normally runs in a window to run as a shell script in the background (like calling the Unix Executable in a shell script?


Thanks!

Offline

 

#2 2017-09-21 02:59:06 pm

artphotodude
Member
Registered: 2012-10-15
Posts: 45

Re: Keystroking to Terminal Application...

OK Figured Out BOTH things (will post info once this is all done), but have a couple of other questions. 

I can run it as a background 'Shell' process, but how then do I send commands to it?


AND

I need to get the initial output of it to populate my choices to control, and since it is a stay-open executable, how to I funnel the output back to Applescript, since it doesn't close and therefore doesn't output??


Is there any Applescript Framework (or bash one that I can call from Applescript) to send and receive input to and from running, non-stop executables?

Offline

 

Board footer

Powered by FluxBB

RSS (new topics) RSS (active topics)