text
stringlengths 0
15.7k
| source
stringlengths 6
112
|
---|---|
set end of allGangs to eachGang
|
Bump level.applescript
|
windowSize's windowSize({direction:"UP", resize:0})
|
winMoveScreenUp.applescript
|
set theName to q name of eachCue
|
Remove file extension from name.applescript
|
set lastChars to text -6 thru -1 of theName
|
Remove file extension from name.applescript
|
if lastChars contains "." then
|
Remove file extension from name.applescript
|
set thePos to ((6 - ((offset of "." in lastChars) - 2)) * -1)
|
Remove file extension from name.applescript
|
set newName to text 1 thru thePos of theName
|
Remove file extension from name.applescript
|
set q name of eachCue to newName
|
Remove file extension from name.applescript
|
display alert "That may have failed for some of the selected cues, but it probably didn't break anything"
|
Remove file extension from name.applescript
|
set carpetaOrigen to choose folder with prompt "Selecciona la carpeta:"
|
remueveDuplicados.scpt
|
set losArchivos to every file of carpetaOrigen as alias list
|
remueveDuplicados.scpt
|
set contarArchivos to count losArchivos
|
remueveDuplicados.scpt
|
repeat with i from 1 to contarArchivos - 1
|
remueveDuplicados.scpt
|
set elArchivo to item i of losArchivos
|
remueveDuplicados.scpt
|
set recuentroNombres to count (name of file elArchivo)
|
remueveDuplicados.scpt
|
set rutaArchivo to POSIX path of elArchivo
|
remueveDuplicados.scpt
|
set checksumMD5 to last word of (do shell script "md5 '" & rutaArchivo & "'")
|
remueveDuplicados.scpt
|
repeat with j from i + 1 to contarArchivos
|
remueveDuplicados.scpt
|
set otroArchivo to item j of losArchivos
|
remueveDuplicados.scpt
|
set rutaOtroArchivo to POSIX path of otroArchivo
|
remueveDuplicados.scpt
|
if last word of (do shell script "md5 '" & rutaOtroArchivo & "'") = checksumMD5 then
|
remueveDuplicados.scpt
|
if recuentroNombres < (count (name of file otroArchivo)) then
|
remueveDuplicados.scpt
|
move otroArchivo to trash
|
remueveDuplicados.scpt
|
move elArchivo to trash
|
remueveDuplicados.scpt
|
display notification "Los archivos duplicados han sido enviados a la papelera:" with title "Proceso finalizado"
|
remueveDuplicados.scpt
|
use framework "CoreImage"
|
GetQRPayload.scpt
|
on getQRPayload(imagePath)
|
GetQRPayload.scpt
|
set theImage to current application's NSImage's alloc()'s initWithContentsOfFile:imagePath
|
GetQRPayload.scpt
|
set theCIImage to current application's CIImage's imageWithData:(theImage's TIFFRepresentation())
|
GetQRPayload.scpt
|
set theDetector to my (CIDetector's detectorOfType:(my CIDetectorTypeQRCode) context:(my CIContext's context()) options:(missing value))
|
GetQRPayload.scpt
|
set theFeatures to theDetector's featuresInImage:theCIImage
|
GetQRPayload.scpt
|
set theResult to ""
|
GetQRPayload.scpt
|
repeat with theFeature in theFeatures
|
GetQRPayload.scpt
|
set theResult to theResult & theFeature's messageString() & ", "
|
GetQRPayload.scpt
|
if length of theResult > 0 then
|
GetQRPayload.scpt
|
set theResult to text 1 thru ((length of theResult) - 2) of theResult
|
GetQRPayload.scpt
|
end getQRPayload
|
GetQRPayload.scpt
|
return getQRPayload("/Users/exampleUser/Downloads/image.png")
|
GetQRPayload.scpt
|
use framework "CoreLocation"
|
CurrentLocation.scpt
|
set theLocation to (missing value)
|
CurrentLocation.scpt
|
set maxSeconds to 10
|
CurrentLocation.scpt
|
set timeStarted to (current date)
|
CurrentLocation.scpt
|
on getCurrentLocation()
|
CurrentLocation.scpt
|
global theLocation, maxSeconds, timeStarted
|
CurrentLocation.scpt
|
set locationManager to current application's CLLocationManager's alloc()'s init()
|
CurrentLocation.scpt
|
locationManager's requestAlwaysAuthorization()
|
CurrentLocation.scpt
|
locationManager's setDelegate:me
|
CurrentLocation.scpt
|
locationManager's requestLocation()
|
CurrentLocation.scpt
|
repeat while theLocation is (missing value) and (current date) - timeStarted < maxSeconds
|
CurrentLocation.scpt
|
return last item of theLocation
|
CurrentLocation.scpt
|
end getCurrentLocation
|
CurrentLocation.scpt
|
on locationManager:locationManager didUpdateLocations:locations
|
CurrentLocation.scpt
|
global theLocation
|
CurrentLocation.scpt
|
set theLocation to locations
|
CurrentLocation.scpt
|
end locationManager:didUpdateLocations:
|
CurrentLocation.scpt
|
on locationManager:locationManager didFailWithError:err
|
CurrentLocation.scpt
|
error err's localizedDescription() as text
|
CurrentLocation.scpt
|
end locationManager:didFailWithError:
|
CurrentLocation.scpt
|
set myLocation to getCurrentLocation()
|
CurrentLocation.scpt
|
if myLocation is not (missing value) then
|
CurrentLocation.scpt
|
return myLocation's coordinate()
|
CurrentLocation.scpt
|
set noteTitleToFind to "TEST Note"
|
EN%20Mac%20Append%20Note%20OR%20Create%20New%20Note%20(AS).applescript
|
set nbName to "TestExtractText"
|
EN%20Mac%20Append%20Note%20OR%20Create%20New%20Note%20(AS).applescript
|
set tagList to {"TEST"}
|
EN%20Mac%20Append%20Note%20OR%20Create%20New%20Note%20(AS).applescript
|
set noteHTMLAppend to "<div>Append to Found Note</div>"
|
EN%20Mac%20Append%20Note%20OR%20Create%20New%20Note%20(AS).applescript
|
set noteContentStr to "New Note was created."
|
EN%20Mac%20Append%20Note%20OR%20Create%20New%20Note%20(AS).applescript
|
set startDelim to "|["
|
EN%20Mac%20Append%20Note%20OR%20Create%20New%20Note%20(AS).applescript
|
set endDelim to "]|"
|
EN%20Mac%20Append%20Note%20OR%20Create%20New%20Note%20(AS).applescript
|
set ansRec to display dialog ¬
|
EN%20Mac%20Append%20Note%20OR%20Create%20New%20Note%20(AS).applescript
|
"ENTER Note Title to Search For:" default answer noteTitleToFind ¬
|
EN%20Mac%20Append%20Note%20OR%20Create%20New%20Note%20(AS).applescript
|
with title (name of me) ¬
|
EN%20Mac%20Append%20Note%20OR%20Create%20New%20Note%20(AS).applescript
|
set noteTitleToFind to text returned of ansRec
|
EN%20Mac%20Append%20Note%20OR%20Create%20New%20Note%20(AS).applescript
|
"ENTER Notebook Search For:" default answer nbName ¬
|
EN%20Mac%20Append%20Note%20OR%20Create%20New%20Note%20(AS).applescript
|
set nbName to text returned of ansRec
|
EN%20Mac%20Append%20Note%20OR%20Create%20New%20Note%20(AS).applescript
|
set noteList to find notes "notebook:\"" & nbName & "\" intitle:\"" & noteTitleToFind & "\""
|
EN%20Mac%20Append%20Note%20OR%20Create%20New%20Note%20(AS).applescript
|
set numNotes to count of noteList
|
EN%20Mac%20Append%20Note%20OR%20Create%20New%20Note%20(AS).applescript
|
if (numNotes = 1) then -- ONE NOTE FOUND --
|
EN%20Mac%20Append%20Note%20OR%20Create%20New%20Note%20(AS).applescript
|
set oNoteSel to item 1 of noteList
|
EN%20Mac%20Append%20Note%20OR%20Create%20New%20Note%20(AS).applescript
|
else if (numNotes = 0) then -- NO NOTES FOUND ---
|
EN%20Mac%20Append%20Note%20OR%20Create%20New%20Note%20(AS).applescript
|
display dialog "Note NOT Found with Title:" & return & noteTitleToFind
|
EN%20Mac%20Append%20Note%20OR%20Create%20New%20Note%20(AS).applescript
|
set oNoteSel to ""
|
EN%20Mac%20Append%20Note%20OR%20Create%20New%20Note%20(AS).applescript
|
else --- MULTIPLE NOTES FOUND ---
|
EN%20Mac%20Append%20Note%20OR%20Create%20New%20Note%20(AS).applescript
|
set pickList to {}
|
EN%20Mac%20Append%20Note%20OR%20Create%20New%20Note%20(AS).applescript
|
set iNote to 0
|
EN%20Mac%20Append%20Note%20OR%20Create%20New%20Note%20(AS).applescript
|
repeat with oNote in noteList
|
EN%20Mac%20Append%20Note%20OR%20Create%20New%20Note%20(AS).applescript
|
set iNote to iNote + 1
|
EN%20Mac%20Append%20Note%20OR%20Create%20New%20Note%20(AS).applescript
|
set modDate to (modification date of oNote)
|
EN%20Mac%20Append%20Note%20OR%20Create%20New%20Note%20(AS).applescript
|
set modDateStr to short date string of modDate
|
EN%20Mac%20Append%20Note%20OR%20Create%20New%20Note%20(AS).applescript
|
set end of pickList to (startDelim & iNote & endDelim & " " & modDateStr & " | " & (title of oNote))
|
EN%20Mac%20Append%20Note%20OR%20Create%20New%20Note%20(AS).applescript
|
set noteSelected to choose from list pickList ¬
|
EN%20Mac%20Append%20Note%20OR%20Create%20New%20Note%20(AS).applescript
|
with prompt ¬
|
EN%20Mac%20Append%20Note%20OR%20Create%20New%20Note%20(AS).applescript
|
"Multiple Notes found for Title:" & return & noteTitleToFind ¬
|
EN%20Mac%20Append%20Note%20OR%20Create%20New%20Note%20(AS).applescript
|
& return & return & "Select the Note to Use in Notebook: " & nbName ¬
|
EN%20Mac%20Append%20Note%20OR%20Create%20New%20Note%20(AS).applescript
|
& return & "(Press OK without selection for new note)" OK button name ¬
|
EN%20Mac%20Append%20Note%20OR%20Create%20New%20Note%20(AS).applescript
|
"OK" cancel button name ¬
|
EN%20Mac%20Append%20Note%20OR%20Create%20New%20Note%20(AS).applescript
|
"Cancel" multiple selections allowed false ¬
|
EN%20Mac%20Append%20Note%20OR%20Create%20New%20Note%20(AS).applescript
|
with empty selection allowed
|
EN%20Mac%20Append%20Note%20OR%20Create%20New%20Note%20(AS).applescript
|
if noteSelected is false then error number -128 -- user cancelled
|
EN%20Mac%20Append%20Note%20OR%20Create%20New%20Note%20(AS).applescript
|
if noteSelected ≠ {} then
|
EN%20Mac%20Append%20Note%20OR%20Create%20New%20Note%20(AS).applescript
|
set iNote to my extractIndex(noteSelected, startDelim, endDelim)
|
EN%20Mac%20Append%20Note%20OR%20Create%20New%20Note%20(AS).applescript
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.