Skip to content

Instantly share code, notes, and snippets.

@comfuture
Last active September 13, 2017 01:19
Show Gist options
  • Star 2 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save comfuture/cb88216c66de42acbbc375c48cb35045 to your computer and use it in GitHub Desktop.
Save comfuture/cb88216c66de42acbbc375c48cb35045 to your computer and use it in GitHub Desktop.
#!/usr/bin/osascript
on run argv
set nr to item 1 of argv
set msg to item 2 of argv
tell application "System Events"
tell application "Messages" to activate
end tell
tell application "Messages"
set Messages to get id of first service
set receipant to buddy nr of service id Messages
send msg to receipant
end tell
end run
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment