Skip to content

Instantly share code, notes, and snippets.

View sherbondy's full-sized avatar

Ethan Sherbondy sherbondy

View GitHub Profile
/*
Create a swipe gesture recognizer to recognize right swipes (the default).
We're only interested in receiving messages from this recognizer, and the view will take ownership of it, so we don't need to keep a reference to it.
*/
recognizer = [[UISwipeGestureRecognizer alloc] initWithTarget:self action:@selector(handleSwipeFrom:)];
[self.view addGestureRecognizer:recognizer];
[recognizer release];
/*
Create a swipe gesture recognizer to recognize left swipes.
@sherbondy
sherbondy / gist:867159
Created March 12, 2011 09:46
npm link log
npm link
npm info it worked if it ends with ok
npm info using [email protected]
npm info using [email protected]
npm info link /Users/ethan/node/c4
npm info preinstall [email protected]
npm info install [email protected]
npm info postinstall [email protected]
npm info predeactivate [email protected]
npm info deactivate [email protected]
@sherbondy
sherbondy / mobile_example.html
Created April 7, 2011 20:30
Mobile website example.
<!DOCTYPE HTML>
<html>
<head>
<title>{% block title1 %}Tetribe{% endblock %} // Tetribe</title>
<link rel="apple-touch-icon" href="/static/2/apple-touch-icon.png">
<link rel="icon" type="image/png" href="/static/2/favicon.png">
<link rel="stylesheet" href="/static/2/style.css" type="text/css" media="screen">
<meta name="viewport" content="width = device-width, initial-scale = 1.0,
maximum-scale = 1.0, user-scalable = no">
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
Thread 1 name: Dispatch queue: com.apple.root.default-priority
Thread 1 Crashed:
0 libsystem_kernel.dylib 0x3558fa1c __pthread_kill + 8
1 libsystem_c.dylib 0x356663b4 pthread_kill + 52
2 libsystem_c.dylib 0x3565ebf8 abort + 72
3 libsystem_c.dylib 0x35672822 szone_error + 210
4 libsystem_c.dylib 0x356728f4 free_tiny_botch + 64
5 libsystem_c.dylib 0x356778dc szone_free + 364
6 libsystem_c.dylib 0x35699fa4 malloc_zone_free + 60
7 CoreFoundation 0x30935e08 __CFAllocatorSystemDeallocate + 8
Thread 1 name: Dispatch queue: com.apple.root.default-priority
Thread 1 Crashed:
0 libsystem_kernel.dylib 0x3558fa1c __pthread_kill + 8
1 libsystem_c.dylib 0x356663b4 pthread_kill + 52
2 libsystem_c.dylib 0x3565ebf8 abort + 72
3 libsystem_c.dylib 0x35672822 szone_error + 210
4 libsystem_c.dylib 0x356728f4 free_tiny_botch + 64
5 libsystem_c.dylib 0x356778dc szone_free + 364
6 libsystem_c.dylib 0x35699fa4 malloc_zone_free + 60
7 CoreFoundation 0x30935e08 __CFAllocatorSystemDeallocate + 8
<img src="http://farm7.staticflickr.com/6078/6069179258_1a48e7da11_s.jpg" width="75" height="75" alt="B-pure-love-oak" class="pc_img" border="0"><img src="http://farm7.staticflickr.com/6072/6069179452_ea8f30b4fd_s.jpg" width="75" height="75" alt="A-iPhone-Mouth" class="pc_img" border="0"><img src="http://farm7.staticflickr.com/6203/6068632647_4fb50cba51_s.jpg" width="75" height="75" alt="B-mount_kailash_jumping" class="pc_img" border="0"><img src="http://farm7.staticflickr.com/6080/6068632799_c023ec8ef1_s.jpg" width="75" height="75" alt="B-scorpion-pose" class="pc_img" border="0"><img src="http://farm7.staticflickr.com/6208/6068632951_4471a04d66_s.jpg" width="75" height="75" alt="IMG_6290" class="pc_img" border="0"><img src="http://farm7.staticflickr.com/6088/6068633107_fbf498872f_s.jpg" width="75" height="75" alt="A-head-shot-2-flower-shirt" class="pc_img" border="0"><img src="http://farm7.staticflickr.com/6184/6069180212_be4605cb47_s.jpg" width="75" height="75" alt="B-star-beard" class="pc_img" border="0"><
@sherbondy
sherbondy / project.clj
Created May 19, 2012 23:38
sherbondy debugging
(defproject sherbondy "0.1.1-SNAPSHOT"
:description "Families should have a presence on the web"
:url "http://www.sherbondy.com"
:license {:name "Eclipse Public License"
:url "http://www.eclipse.org/legal/epl-v10.html"}
:source-path "src-clj"
:dependencies [[org.clojure/clojure "1.3.0"]
[org.clojure/algo.generic "0.1.0"]
[org.clojure/tools.logging "0.2.3"]
[ring/ring-core "1.1.0"]
@sherbondy
sherbondy / facebook.js
Created June 2, 2012 01:28
externs for clojurescript
var FB = {};
FB.api = function(location, callback){};
FB.getLoginStatus = function(callback){};
FB.init = function(options){};
FB.login = function(callback, scope){};
FB.logout = function(callback){};
FB.Event = {};
FB.Event.subscribe = function(evt, callback){};
@sherbondy
sherbondy / facebook.js
Created August 19, 2012 07:43
Facebook externs for cljsbuild
FB = {};
FB.api = function(location, callback){};
FB.getLoginStatus = function(callback){};
FB.init = function(options){};
FB.login = function(callback, scope){};
FB.logout = function(callback){};
FB.Event = {};
@sherbondy
sherbondy / assignment0.scm
Created September 6, 2012 04:28
First assignment for SICM, Excercises 8.1 and 8.2
(define (f x y)
(* (square x) (cube y)))
(define (g x y)
(up (f x y) 'y))
; just for giggles
(define (helix t)
(up (cos t) (sin t) t))