Skip to content

Instantly share code, notes, and snippets.

View technoweenie's full-sized avatar
👾
beep boop

technoweenie

👾
beep boop
View GitHub Profile
@technoweenie
technoweenie / Gemfile
Created November 14, 2011 05:46 — forked from rwjblue/Gemfile
Simple CQL to Thrift Comparison in ruby
source :rubygems
gem 'rake'
gem 'forgery'
gem 'cassandra-cql', :path => '../cassandra-cql'
gem 'cassandra', :path => '../cassandra'
gem 'perftools.rb'
gem 'rbtrace'

Drift: an iPad app for GitHub Gists

Greg Borenstein (he hooked up our stoplight to our ci build system last year) and Devin Chalmers just announced that Drift is available on the App Store. Drift is an always-versioned text editor for the iPad, backed by GitHub Gists.

![](https://github-images.s3.amazonaws.com/blog/2011/drift.png)

Not only is this a nice and simple interface around Gist, but it also serves as an example of how to develop a native app around a 3rd party API. Greg and Devin have no official connection to GitHub, but were rejected several times by Apple for violating rule 11.13. Basically, any app that leads to an external site for purchases or subscriptions is rejected, even if the app doesn't require a paid ac

Welcome to Drift!

Drift is an always-already versioned, cloud-backed text editor. You can use it to take notes, and save them in the GitHub cloud.

Your gists are always saved locally, and any changes you make will get pushed to GitHub's servers.

To name a gist, touch its name in the toolbar.

You can use the share button at the top-right to copy a link to one of your gists, or view it on the web in Safari.

# Luna requires parens on all function calls, except for one exception.
# But, you should always use parens to keep Luna HAPPY
# HAPPY
person pets select(: pet
pet species == 'ferret' && pet age > 4
)
# SAD
person pets select(): pet
@technoweenie
technoweenie / gist:1072829
Created July 8, 2011 21:12
.netrc file so you can push/pull to https git repos without entering your creds all the time
machine github.com
login technoweenie
password SECRET
machine api.github.com
login technoweenie
password SECRET
@technoweenie
technoweenie / pinger.rb
Created June 17, 2011 14:38
ZeroMQ pub/sub demo
require 'zmq'
context = ZMQ::Context.new
pub = context.socket ZMQ::PUB
pub.setsockopt ZMQ::IDENTITY, 'ping-pinger'
pub.bind 'tcp://*:5555'
i=0
loop do
pub.send "ping pinger #{i+=1}" ; sleep 1
end
@technoweenie
technoweenie / gist:975010
Created May 16, 2011 18:25
Response from a support request to the DoD DPS system regarding the inability the login.
Subject: RE: DPS Site Access
No idea what you mean by script information, are you using a Mac? No Mac support for DPS. DPS
requires Windows based systems with Internet Explorer 7 or 8. If you are using IE 8, you will
have to change the zoom level to 150% (bottom right of IE8) from 100% for compatibility reasons.
Remember only IE7 and 8 supported by DPS, No Firefox, Chrome, Safari, and pop up blocker must be
turned off to access DPS and this is listed under TOOLS.
@technoweenie
technoweenie / api_documentation.rb
Created April 29, 2011 11:54
discarded sinatra documentation extension
# Sinatra module for documenting an API. This info can be exported as JSON
# and used to generate other forms of documentation.
#
# Example documentation for a GET request:
#
# desc "List issues for this Repository"
# param :milestone, Fixnum
# param :state, String, :default => 'open', :choices => %w(open closed)
# get "/repos/:user/:repo/issues" do
# ...
@technoweenie
technoweenie / gist:933716
Created April 21, 2011 04:25
ignored paths in the GitHub language guesser
IgnorePaths = %w(
yui
tiny_mce
ckeditor
redbox
active_scaffold
rico_corner
code_highlighter
vendor
bundle
@technoweenie
technoweenie / minimal-logger.coffee
Created March 9, 2011 20:25
Minimal node.js logger
# logger = require('logger').create()
# logger.info("blah")
# => [2011-3-3T20:24:4.810 info (5021)] blah
# logger.debug("boom")
# =>
# logger.level = Logger.levels.debug
# logger.debug(function() { return "booom" })
# => [2011-3-3T20:24:4.810 error (5021)] booom
class Logger
constructor: (options) ->