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
#!/bin/bash | |
osascript -e "tell application \"Address Book\"" \ | |
-e " set firstParam to \"$1\"" \ | |
-e " set secondParam to \"$2\"" \ | |
-e " set thirdParam to \"$3\"" \ | |
-e " set fourthParam to \"$4\"" \ | |
-e " set contactEmailLabel to \"\"" \ | |
-e " set spaceOffset to (offset of \" \" in firstParam)" \ | |
-e " if (spaceOffset is not equal to 0) then" \ | |
-e " set AppleScript's text item delimiters 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
sudo defaults write /Library/Preferences/com.apple.windowserver DisplayResolutionEnabled -bool YES; | |
sudo defaults delete /Library/Preferences/com.apple.windowserver DisplayResolutionDisabled; | |
// by the way, you need to logout and log back in for this to take effect. Or at least that's what | |
// Quartz Debug says. Who knows, maybe it's lying? | |
// P.S. Go to [Apple menu --> System Preferences --> Displays --> Display --> Scaled] after logging | |
// back in, and you'll see a bunch of "HiDPI" resolutions in the list to choose from. |
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 "Notes" | |
set note_body_list to (get body of every note) | |
end tell | |
set note_count to (count of note_body_list) | |
set blah_folder to choose folder | |
set blah_path to POSIX path of blah_folder | |
repeat with i from 1 to note_count | |
set filename_string to ((blah_path & "note" & (i as string) & ".html") as text) |
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
func testReservationListPositions() { | |
let moc = CoreDataStack.sharedStack().mainObjectContext | |
let reservationListVC = ReservationListViewController() | |
do { | |
let reservation1 = try ReservationFactory.generateWithTemplate(ReservationFactory.Template(), parentContext: moc) | |
} catch { | |
print(error) | |
} | |