-
-
Save rempargo/29f092c28adef3a0f96c to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env ruby -wKU | |
require "rubygems" | |
require "appscript" | |
include Appscript | |
chrome = app("Google Chrome") | |
safari = app("Safari") | |
chrome_tab = chrome.windows[1].active_tab | |
save_url = chrome_tab.URL.get | |
save_title = chrome_tab.name.get | |
safari.add_reading_list_item(save_url, :with_title => save_title) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
But this in Applescript is much better:
In Alfred's Workflow, add Actions then Run Script
Select as language /usr/bin/osascript
The only thing was, I didn't realised it worked allready, no signs of this process in the screen (like you would see with a typical GUI macro recorder => selecting URL, switch to safari, etc...)