I hereby claim:
- I am stith on github.
- I am stith (https://keybase.io/stith) on keybase.
- I have a public key whose fingerprint is 34D5 7F07 9811 B5EA B7D4 5915 7C4E EFA1 B205 55BD
To claim this, I am signing this object:
doStuff().then(function(things) { | |
if (!things) { | |
throw new Error("Here I want to skip everything else, including the 'then's after the next catch.."); | |
} | |
if (canMakeNewThing) { | |
// This should continue to the next 'then' | |
return someNewThing.save(); | |
} |
#!/usr/bin/python | |
# Quick and dirty demonstration of CVE-2014-0160 by Jared Stafford (jspenguin@jspenguin.org) | |
# The author disclaims copyright to this source code. | |
# Mirror from http://s3.jspenguin.org/ssltest.py | |
import sys | |
import struct | |
import socket | |
import time |
I hereby claim:
To claim this, I am signing this object:
grep -lir "some text" * | |
// -l outputs only names of files containing text instead of the line | |
// -i ignores case | |
// -r recursive, go into subdirectories |
User: Will you roll a dice, please? | |
Cleverbot: I don't understand your request. | |
User: Roll a dice. | |
Cleverbot: Four. | |
User: Roll a dice. |
def allocated_date=(new_value) | |
write_attribute(:allocated_date, new_value) unless read_attribute(:allocated_date) | |
end |
#!/usr/bin/env ruby | |
# Testing the aasm gem to see how to get one aasm_event to decide | |
# which state to transition into | |
require 'rubygems' | |
require 'aasm' | |
class TestObject | |
include AASM | |
aasm_initial_state :active | |
NSPredicate *predicate = [NSPredicate predicateWithFormat:@"name = %@",someVariableNameLol]; | |
NSArray *filteredArray = [friends filteredArrayUsingPredicate:predicate]; |
Product Names Guidelines | |
You may use Apple, iPad, or any other Apple word mark (but not the Apple Logo or other Apple-owned graphic symbol/logo) in a referential phrase on packaging or promotional/advertising materials to describe that the third party product is compatible with the referenced Apple product or technology, provided they comply with the following requirements. | |
a. The Apple word mark is not part of the product name. | |
b. The Apple word mark is used in a referential phrase such as "runs on," "for use with," "for," or "compatible with." | |
c. The Apple word mark appears less prominent than the product name. | |
d. The product is in fact compatible with, or otherwise works with, the referenced Apple product. | |
e. The reference to Apple does not create a sense of endorsement, sponsorship, or false association with Apple or Apple products or services. | |
f. The use does not show Apple or its products in a false or derogatory light. |
//~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ | |
// Debug | |
//~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ | |
#define DEBUG_ON // Toggle to DEBUG_OFF or comment out to hide all debug code | |
#ifdef DEBUG_ON | |
#define MSLog(format, ...) CFShow([[NSString stringWithFormat:@"<%@:%d> ",[[NSString stringWithUTF8String:__FILE__] lastPathComponent],__LINE__] stringByAppendingFormat:format, ## __VA_ARGS__]) | |
#else | |
#define MSlog(format, ...) | |
#endif |