Bone warming goodness on a cold rainy day.
- Smoked Salmon (a typical store package seems to work fine)
- Small container heavy cream
- Handful of nice small potatoes (red new, yukon gold, whatev)
- Couple of standard issue carrots
-- View an Aperture photo on flickr | |
-- Assumes a custom metadata field in Aperture named "Flickr URL" exists. | |
tell application "Aperture" | |
-- selection always returns image versions | |
set selectedImages to (get selection) | |
if (count of items in selectedImages) > 0 then | |
repeat with i from 1 to count of selectedImages | |
tell library 1 | |
set img to item i of selectedImages |
-- Copy the Aperture Version Name to the IPTC ObjectName (Title field in Aperture) | |
tell application "Aperture" | |
set selectedImages to (get selection) | |
if selectedImages is {} then | |
error "Please select an image." | |
else | |
repeat with i from 1 to count of selectedImages | |
tell library 1 | |
tell item i of selectedImages |
sed `perl -e "print $RANDOM"`"q;d" /usr/share/dict/words | tr -d '\n' | pbcopy |
describe "just another afternoon” do | |
jeff = Factory.create(:loser) | |
artie = Cat.new(:name => "Artie", :size => "long", :color => "black”) | |
helpeless_victim = Victim.new(:type => ['Mouse, 'Bird', 'Mole', 'Rat'].sample) | |
artie.catch(helpless_victim) | |
while helpeless_victim.is_alive? | |
artie.torture(victim) | |
sleep 10 |
THIS STRING IS 256 CHARACTERS xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx |
Fix for missing documentation indexes and other anomolies in the Xcode documentation viewer. Mine seemed to get all borked up with some beta relaeases. Shamelessly ripped off from this thread.
~/Library/Caches/com.apple.dt.Xcode
.~/Library/Developer/Shared/Documentation/DocSets/
./Applications/Xcode.app/Contents/Developer/Documentation/DocSets/
.To display the current version of an iOS app in the settings
Settings.bundle/Root.plist
<key>PreferenceSpecifiers</key>
<array>
<dict>
<key>Type</key>
PSTitleValueSpecifier
func logPretty(message: String? = nil, file: String = __FILE__, line: UInt = __LINE__, function: StaticString = __FUNCTION__) { | |
var pretty = "\((file as NSString).lastPathComponent)(\(line)) : \(function)" | |
if let message = message where !message.isEmpty { | |
pretty += " ☞ \(message)" | |
} | |
print(pretty) | |
} |
// | |
// NSPersonNameComponents.swift | |
// | |
import Foundation | |
extension NSPersonNameComponents { | |
// Because the web is generally xenophobic… | |
var xenophobicName: (firstName: String, lastName: String)? { | |