How to Use osascript: Run AppleScript from the Mac Terminal
The osascript command runs AppleScript — and JavaScript — straight from the Terminal, which makes it the bridge between a shell script and the Mac’s GUI layer. It is how a shell script pops a…









