This file contains 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
tell application "Byword" | |
set theDocument to file of document of window 1 | |
end tell | |
tell application "Marked" | |
open theDocument | |
end tell |
This file contains 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/python | |
import shlex, subprocess | |
import os, os.path | |
import sys | |
import time | |
import argparse | |
FILE_NAME = 'amazon.txt' | |
IMAGE_PATH = '~/Documents/BookImages/' |
This file contains 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
on open dropped_item | |
set file_list to items of dropped_item | |
repeat with a_file in file_list | |
tell application "Finder" to set c_date to creation date of a_file | |
tell application "Evernote" to create note from file a_file notebook Text_Notes created c_date | |
end repeat | |
end open |
This file contains 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
set theURL to "http://images.amazon.com/images/P/" & (the clipboard) & ".01.LZZZZZZZ.jpg" | |
tell application "Safari" | |
set URL of current tab to theURL | |
end tell |
This file contains 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
set theURL to "http://images.amazon.com/images/P/" & (the clipboard) & ".01.LZZZZZZZ.jpg" | |
tell application "Google Chrome" | |
set URL of last tab of window 1 totheURL | |
end tell |
This file contains 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
on handle_string(the_text) | |
set time_string to do shell script "date '+%H:%M:%S'" | |
set date_string to do shell script "date '+%Y-%m-%d'" | |
set message to "<p><b>" & time_string & "</b> | " & the_text & "</p>" | |
tell application "Evernote" | |
set matches to find notes (date_string as text) & " notebook:Log" | |
if (count of matches) is 1 then | |
set the_note to item 1 of matches |
This file contains 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
on handle_string(search_query) | |
tell application "Evernote" | |
open collection window with query string (search_query as text) | |
activate | |
end tell | |
end handle_string |
This file contains 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
import os, subprocess | |
desc = [] | |
c_line = "man 1 %s | col -b > /tmp/man.txt" | |
s_line = "cat /tmp/man.txt | sed -n -e \"/^NAME/,/^SYNOPSIS/ p\" | grep -v -e \"^[A-Z]\"" | |
dirs = ["/usr/bin/", "/usr/sbin/"] | |
for dir in dirs: | |
for f in os.listdir(dir): |
This file contains 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
tell application "Evernote" | |
synchronize | |
set the_Selection to selection | |
set the_Title to title of (item 1 of the_Selection) | |
set the_HTML to HTML content of (item 1 of the_Selection) | |
set the_Text to do shell script "echo " & quoted form of the_HTML & space & "| textutil -convert txt -stdin -stdout" | |
set the_Tags to {} |
This file contains 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
tell application "Safari" to set theURL to URL of current tab of window 1 | |
if theURL contains "some unique part of your URL" then | |
tellapplication "Safari" | |
closecurrent tab ofwindow1 | |
endtell | |
set_private_browsing() | |
else | |
set_private_browsing() | |
tellapplication "Safari" | |
makenew tabinwindow1 |
OlderNewer