Re: Using cliclick with apple script
Re: Using cliclick with apple script
- Subject: Re: Using cliclick with apple script
- From: Christopher Stone <email@hidden>
- Date: Sun, 24 Jul 2016 18:08:12 -0500
On Jul 24, 2016, at 17:15, -dan d. <email@hidden> wrote:
There is a small cli utility that can controll all aspects of the apple desktop from the command line, cliclick. It is free and the developer is very open to requests for changes:
Hey XB,
Yes, it's pretty spiffy.
I can put a cliclick macro series of keystrokes in a shell script but AppleScript seems not to evoke it, it simply seems to ignore it.
AppleScript's shell environment is not the same as your log-in shell.
Run this in the Script Editor:
----------------------------------------------------------------- set shCMD to " echo $PATH " do shell script shCMD -----------------------------------------------------------------
Compare to echo $PATH in the Terminal.
This sort of thing should work, although you might have to adjust the path(s) a bit.
----------------------------------------------------------------- set shCMD to " export PATH=/opt/local/bin:/opt/local/sbin:/usr/local/bin:$PATH; cliclick m:500,500 " do shell script shCMD -----------------------------------------------------------------
If you're wanting to automate non-scriptable apps then you should discover more about System Events and GUI-Scripting and perhaps Keyboard Maestro.
-- Best Regards, Chris
|
_______________________________________________
Do not post admin requests to the list. They will be ignored.
AppleScript-Users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
Archives: http://lists.apple.com/archives/applescript-users
This email sent to email@hidden