text
stringlengths
0
15.7k
source
stringlengths
6
112
set mylist to make new list with properties {name:_projectlist}
Things to Reminders.applescript
if _status is "open" then
Things to Reminders.applescript
if _duedate is not missing value then
Things to Reminders.applescript
make new reminder with properties {name:name of _todo, body:_note, due date:_duedate, remind me date:_duedate}
Things to Reminders.applescript
make new reminder with properties {name:name of _todo, body:_note}
Things to Reminders.applescript
end if #_status is "open"
Things to Reminders.applescript
end tell #tell list
Things to Reminders.applescript
end exportThingsProjets
Things to Reminders.applescript
on convertTags(_tags)
Things to Reminders.applescript
set _returntext to ""
Things to Reminders.applescript
repeat with i from 1 to count of _tags by 1
Things to Reminders.applescript
set _item to item _counter of _tags
Things to Reminders.applescript
set _returntext to "#" & name of item i of _tags & _returntext
Things to Reminders.applescript
set _counter to _counter + 1
Things to Reminders.applescript
return _returntext
Things to Reminders.applescript
end convertTags
Things to Reminders.applescript
on stringToList(theString, myDelimiters)
Things to Reminders.applescript
if theString contains myDelimiters then
Things to Reminders.applescript
set theSavedDelimiters to AppleScript's text item delimiters
Things to Reminders.applescript
set text item delimiters to myDelimiters
Things to Reminders.applescript
set outList to text items of theString
Things to Reminders.applescript
set text item delimiters to theSavedDelimiters
Things to Reminders.applescript
return outList
Things to Reminders.applescript
return {theString}
Things to Reminders.applescript
end stringToList
Things to Reminders.applescript
on choosefromList(mylist, myPrompttext)
Things to Reminders.applescript
choose from list mylist with title myPrompttext
Things to Reminders.applescript
set myResult to result as string
Things to Reminders.applescript
end choosefromList
Things to Reminders.applescript
set mailDropAddress to "YOUR MAIL DROP ADDRESS"
Smart%20OmniFocus%20for%20nvALT.scpt
set l to paragraphs of (do shell script "grep '\\[ x \\]' " & quoted form of p)
Smart%20OmniFocus%20for%20nvALT.scpt
set omnifocusActive to count (every process whose name is "OmniFocus")
Smart%20OmniFocus%20for%20nvALT.scpt
set taskName to (do shell script "n=\"" & v & "\"; echo ${n:6}")
Smart%20OmniFocus%20for%20nvALT.scpt
if omnifocusActive > 0 then
Smart%20OmniFocus%20for%20nvALT.scpt
do shell script "echo \"" & taskNote & "\" | mail -s \"" & taskName & "\" " & mailDropAddress
Smart%20OmniFocus%20for%20nvALT.scpt
output volume of (get volume settings)
volume.applescript
set theFile to file of document of window 1
open in PDF Expert.applescript
POSIX path of theFile
open in PDF Expert.applescript
set shellScript to "open -a \"/Applications/PDF Expert.app\" "
open in PDF Expert.applescript
do shell script shellScript & "\"" & POSIX path of theFile & "\""
open in PDF Expert.applescript
on escapeHtml(theText)
omnifocus-2-evernote.scpt
do shell script "ruby -rcgi -e 'ARGV.each {|a| puts CGI.escape_html(%Q<#{a}>)}' -- " & quoted form of theText
omnifocus-2-evernote.scpt
end escapeHtml
omnifocus-2-evernote.scpt
set theLines to {}
omnifocus-2-evernote.scpt
if number of document window is 0 then
omnifocus-2-evernote.scpt
make new document window with properties {bounds:{0, 0, 500, 500}}
omnifocus-2-evernote.scpt
set theSelectedTasks to value of selected trees of content
omnifocus-2-evernote.scpt
repeat with aTask in theSelectedTasks
omnifocus-2-evernote.scpt
set end of theLines to "<li><en-todo/> " & "<a href=\"omnifocus:///task/" & (id of aTask) & "\">" & my escapeHtml(name of aTask) & "</a><br/><pre>" & my escapeHtml(note of aTask) & "</pre></li>"
omnifocus-2-evernote.scpt
set the text item delimiters of AppleScript to "\n"
omnifocus-2-evernote.scpt
set theLines to theLines as text
omnifocus-2-evernote.scpt
create note with enml "<ul>" & theLines & "</ul>" notebook "Todos" title ("Todos " & (current date) as text)
omnifocus-2-evernote.scpt
set query string of window 1 to "notebook:Todos"
omnifocus-2-evernote.scpt
set calendarsHolder to calendars of calendar 2
Delete Microsoft Outlook Calendars.applescript
repeat with i from 1 to count of calendarsHolder
Delete Microsoft Outlook Calendars.applescript
if name of item i of calendarsHolder contains "Year" then
Delete Microsoft Outlook Calendars.applescript
delete item i of calendarsHolder
Delete Microsoft Outlook Calendars.applescript
if length of textDate is 4 then
bookends-to-devonthink-2.applescript
set textDate to "1/1/" & textDate
bookends-to-devonthink-2.applescript
set resultDate to my date textDate
bookends-to-devonthink-2.applescript
to surname(textName)
bookends-to-devonthink-2.applescript
set r to textName
bookends-to-devonthink-2.applescript
set s to text items of textName
bookends-to-devonthink-2.applescript
if s is not missing value then
bookends-to-devonthink-2.applescript
set r to (item 1 of s) as string
bookends-to-devonthink-2.applescript
return r
bookends-to-devonthink-2.applescript
end surname
bookends-to-devonthink-2.applescript
to authorlist(authors)
bookends-to-devonthink-2.applescript
set r to authors as text
bookends-to-devonthink-2.applescript
end authorlist
bookends-to-devonthink-2.applescript
set theTemplateFile to "/Users/lyndon/Library/Application Support/DEVONthink 3/Templates.noindex/Education/Reference LD.md"
bookends-to-devonthink-2.applescript
set theDatabase to open database "/Users/lyndon/DevonThink/Research.dtBase2"
bookends-to-devonthink-2.applescript
set theRefs to selected publication items
bookends-to-devonthink-2.applescript
set itemCount to count of theRefs
bookends-to-devonthink-2.applescript
if itemCount > 0 then
bookends-to-devonthink-2.applescript
set toProcess to display dialog "You have " & itemCount & " items selected. Would you like to process the selected items or the entire library?" buttons {"Cancel", "Selection", "Library"} default button 3
bookends-to-devonthink-2.applescript
if the button returned of toProcess is "Library" then
bookends-to-devonthink-2.applescript
set theRefs to publication items of group item "DT"
bookends-to-devonthink-2.applescript
else if the button returned of toProcess is "Cancel" then
bookends-to-devonthink-2.applescript
set {theID, theKey, thePaths, dtUUID, origURLs, modDate, theAuthor, theEditor, theDateText, theTitle, theShortTitle, theAbstract, theDOI, theKeywords, theURL} to {id, citekey, path of attachment items, user15, user20, date modified, authors, editors, publication date string, title, short title, abstract, doi, keyword names, url} of theRef
bookends-to-devonthink-2.applescript
if theShortTitle = "" then set theShortTitle to theTitle
bookends-to-devonthink-2.applescript
set theDate to my convertDate(theDateText)
bookends-to-devonthink-2.applescript
set theYear to the year of theDate as string
bookends-to-devonthink-2.applescript
set theBookendsURL to ("bookends://sonnysoftware.com/" & theID) as text
bookends-to-devonthink-2.applescript
repeat 1 times -- dummy loop to allow skipping to next item if not recently modified in Bookends
bookends-to-devonthink-2.applescript
set theRecord to get record with uuid dtUUID in theDatabase
bookends-to-devonthink-2.applescript
if theRecord is missing value then
bookends-to-devonthink-2.applescript
set theFilename to theYear & " " & theShortTitle
bookends-to-devonthink-2.applescript
set theAuthor to paragraphs of theAuthor
bookends-to-devonthink-2.applescript
if (count of theAuthor) is 1 then
bookends-to-devonthink-2.applescript
set s1 to my surname(item 1 of theAuthor)
bookends-to-devonthink-2.applescript
set theFilename to s1 & " " & theFilename
bookends-to-devonthink-2.applescript
else if (count of theAuthor) is 2 then
bookends-to-devonthink-2.applescript
set s2 to my surname(item 2 of theAuthor)
bookends-to-devonthink-2.applescript
set theFilename to s1 & " and " & s2 & " " & theFilename
bookends-to-devonthink-2.applescript
else if (count of theAuthor) > 2 then
bookends-to-devonthink-2.applescript
set theFilename to s1 & " et al " & theFilename
bookends-to-devonthink-2.applescript
set theGroup to create location "/Library/" & theFilename
bookends-to-devonthink-2.applescript
set origURLs to theURL
bookends-to-devonthink-2.applescript
if (modification date of theRecord) > (modDate + (1 * minutes)) then
bookends-to-devonthink-2.applescript