text
stringlengths
0
15.7k
source
stringlengths
6
112
set myVar to ""
convert_images_to_pdf.scpt
repeat with a from 1 to length of thefileList
convert_images_to_pdf.scpt
set testpath1 to POSIX path of item a of thefileList
convert_images_to_pdf.scpt
set testname1 to name of (info for testpath1)
convert_images_to_pdf.scpt
set testname2 to text 1 thru -5 of testname1
convert_images_to_pdf.scpt
set testname3 to oddManOut & testname2 & ".pdf"
convert_images_to_pdf.scpt
do script "convert " & quoted form of item a of thefileList & " " & quoted form of testname3 in theTab
convert_images_to_pdf.scpt
convert notes
Clear all notes.applescript
set ct to count of notes
Clear all notes.applescript
delete notes
Clear all notes.applescript
display alert ct & " notes were deleted."
Clear all notes.applescript
save the front document as "text" in savePath
ASE-Save as text.applescript
open oldPath
ASE-Save as text.applescript
set addDate to todayISOformat()
save chrome tab to Evernote todo list.applescript
set myNote to (find notes "0000000 this is a read later")
save chrome tab to Evernote todo list.applescript
set theNote to item 1 of myNote -- return one note
save chrome tab to Evernote todo list.applescript
set addContent to "<br/><br/>" & tabTitle & "<br/>" & addDate & "<br/>" & "<a href=\"" & tabUrl & "\">" & tabUrl & "</a>"
save chrome tab to Evernote todo list.applescript
set cueTitle to "LX"
Create OSC control cue.applescript
set cuePatch to "2"
Create OSC control cue.applescript
stringBase
Create OSC control cue.applescript
set stringBase to "/eos/cue"
Create OSC control cue.applescript
stringSuffix
Create OSC control cue.applescript
set stringSuffix to "/fire"
Create OSC control cue.applescript
askForInString
Create OSC control cue.applescript
set askForInString to {"Cue List Number", "Cue Number"}
Create OSC control cue.applescript
set askForValue to ""
Create OSC control cue.applescript
set cueColor to "Blue"
Create OSC control cue.applescript
if askForInString is not {} then
Create OSC control cue.applescript
set userString to {}
Create OSC control cue.applescript
repeat with eachItem in askForInString
Create OSC control cue.applescript
display dialog "Please provide " & eachItem with title cueTitle default answer ""
Create OSC control cue.applescript
set end of userString to ("/" & (text returned of result))
Create OSC control cue.applescript
if askForValue is not "" then
Create OSC control cue.applescript
set userValue to (text returned of result)
Create OSC control cue.applescript
set oscCommand to stringBase & (every item of userString as string) & stringSuffix
Create OSC control cue.applescript
set oscCommand to stringBase & stringSuffix
Create OSC control cue.applescript
set oscCommand to oscCommand & " " & userValue
Create OSC control cue.applescript
set networkCue to last item of (selected as list)
Create OSC control cue.applescript
set osc message type of networkCue to custom
Create OSC control cue.applescript
set patch of networkCue to cuePatch
Create OSC control cue.applescript
set custom message of networkCue to oscCommand
Create OSC control cue.applescript
set q name of networkCue to cueTitle & ": " & oscCommand
Create OSC control cue.applescript
set q color of networkCue to cueColor
Create OSC control cue.applescript
set cue target of startCue to networkCue
Create OSC control cue.applescript
set q name of startCue to cueTitle & ": " & oscCommand
Create OSC control cue.applescript
 property folder_path : missing value
Script 16-9.applescript
if folder_path is missing value or not (container folder_path exists) then
Script 16-9.applescript
tell me to set folder_path to (choose folder) as text
Script 16-9.applescript
get folder_path
Script 16-9.applescript
set listOfFiles to contents of folder "Macintosh HD:Users:pat:Desktop:THE_FOLDER"
dayone-import-from-ulysses-text-file.scpt
repeat with i from 1 to count of listOfFiles
dayone-import-from-ulysses-text-file.scpt
set thisFile to item i of listOfFiles
dayone-import-from-ulysses-text-file.scpt
set thisFileAlias to thisFile as alias
dayone-import-from-ulysses-text-file.scpt
set creationDate to (creation date of (get info for thisFileAlias))
dayone-import-from-ulysses-text-file.scpt
set {year:y, month:m, day:d} to creationDate
dayone-import-from-ulysses-text-file.scpt
set timeStr to time string of creationDate
dayone-import-from-ulysses-text-file.scpt
tell (y * 10000 + m * 100 + d) as string to text 1 thru 4 & "-" & text 5 thru 6 & "-" & text 7 thru 8 & " " & timeStr
dayone-import-from-ulysses-text-file.scpt
set dateTimeStr to the result
dayone-import-from-ulysses-text-file.scpt
set thisFile to thisFile as string
dayone-import-from-ulysses-text-file.scpt
set contentsOfFile to read file thisFile as «class utf8»
dayone-import-from-ulysses-text-file.scpt
set contentsOfFile to contentsOfFile as string
dayone-import-from-ulysses-text-file.scpt
set escapeChar to character id 92
dayone-import-from-ulysses-text-file.scpt
set doubleQuoteChar to character id 34
dayone-import-from-ulysses-text-file.scpt
set escapeStr1 to escapeChar & "'"
dayone-import-from-ulysses-text-file.scpt
set escapeStr2 to "\""
dayone-import-from-ulysses-text-file.scpt
set contentsOfFile to my replaceText("'", escapeStr1, contentsOfFile)
dayone-import-from-ulysses-text-file.scpt
set contentsOfFile to my replaceText(doubleQuoteChar, escapeChar & escapeStr2, contentsOfFile)
dayone-import-from-ulysses-text-file.scpt
set char1 to characters 1 thru 1 of result as string
dayone-import-from-ulysses-text-file.scpt
if (char1 = "-") then
dayone-import-from-ulysses-text-file.scpt
set contentsOfFile to "Untitled
dayone-import-from-ulysses-text-file.scpt
" & contentsOfFile
dayone-import-from-ulysses-text-file.scpt
set thecommandstring to "echo \"" & contentsOfFile & "\"|grep -Eo '(#[[:alpha:]-]+)([0-9]?)'"
dayone-import-from-ulysses-text-file.scpt
set tags to "Imported"
dayone-import-from-ulysses-text-file.scpt
set grepResult to ""
dayone-import-from-ulysses-text-file.scpt
set grepResult to do shell script thecommandstring as string
dayone-import-from-ulysses-text-file.scpt
set returnChar to character id 13
dayone-import-from-ulysses-text-file.scpt
set parsedGrepResult to my replaceText("#", "", grepResult)
dayone-import-from-ulysses-text-file.scpt
set parsedGrepResult to my replaceText(returnChar, " ", parsedGrepResult)
dayone-import-from-ulysses-text-file.scpt
set tags to tags & " " & parsedGrepResult as string
dayone-import-from-ulysses-text-file.scpt
set thecommandstring to "echo \"" & contentsOfFile & "\"|LC_CTYPE=en_US.UTF-8 grep -Ev '([#])([[:alpha:]-]+)([0-9])?'"
dayone-import-from-ulysses-text-file.scpt
set contentsOfFile to do shell script thecommandstring
dayone-import-from-ulysses-text-file.scpt
set command to "/usr/local/bin/dayone2 -t " & tags & " -j Import -d='" & dateTimeStr & "' -z='America/New_York' new " & "\"" & contentsOfFile & "\""
dayone-import-from-ulysses-text-file.scpt
do shell script (command)
dayone-import-from-ulysses-text-file.scpt
log "Written item: " & i
dayone-import-from-ulysses-text-file.scpt
do shell script ("cd \"" & current_path & "\"; git add .")
Git Add All.applescript
on getGenreResultListFeedback(query)
playgenre.applescript
set theGenres to getResultsFromQuery(query, "genre") of config
playgenre.applescript
repeat with genreName in theGenres
playgenre.applescript
set genreName to genreName as text
playgenre.applescript
set theSong to (first track of playlist 2 whose genre is genreName)
playgenre.applescript
addResult({uid:("genre-" & genreName), valid:"yes", title:genreName, subtitle:"Genre", icon:songArtworkPath}) of config
playgenre.applescript
addNoResultsItem(query, "genre") of config
playgenre.applescript
end getGenreResultListFeedback
playgenre.applescript
getGenreResultListFeedback(query as text)
playgenre.applescript
property ADDRESSBOOK_DATA_DIR : "~/Library/Application\\ Support/AddressBook"
view_in_alfred.applescript
set theId to id of item 1 of theSelection
view_in_alfred.applescript
set theContactFile to do shell script "mdfind -onlyin " & ADDRESSBOOK_DATA_DIR & " \"kMDItemFSName='" & theId & ".abcdp' && kMDItemContentType='com.apple.addressbook.person'\""
view_in_alfred.applescript
tell application id "com.runningwithcrayons.Alfred" to run trigger "open_file" in workflow "com.temochka.alfred.process" with argument theContactFile
view_in_alfred.applescript
"Hello, " & "World!"
operators.applescript
set the_price to "$" & 6
operators.applescript