Skip to content

Instantly share code, notes, and snippets.

@austenito
austenito / keybase.md
Created March 14, 2014 18:43
Keybase Prove

Keybase proof

I hereby claim:

  • I am austenito on github.
  • I am austenito (https://keybase.io/austenito) on keybase.
  • I have a public key whose fingerprint is 5109 7196 F22F 5549 9B8B 3423 7A21 AEC2 BBA3 B752

To claim this, I am signing this object:

@austenito
austenito / docker_helpers.md
Last active August 29, 2015 14:02
Docker Helpers

sudo docker stop $(sudo docker ps -a -q) && sudo docker rm $(sudo docker ps -a -q)

sudo docker run -i -t --name="hsconsole" --volumes-from happiness-data --link="postgres:db" austenito/ruby-2.1.2 /bin/bash

source /usr/local/share/chruby/chruby.sh
git clone https://github.com/austenito/happiness_service.git
cd happiness_service
export GEM_HOME=/gems/ruby/2.1.2
mkdir pids
class InvoiceRepo
def initialize(invoices)
@invoices = invoices
end
def self.get_instance(invoices)
@invoice_repo ||= new(invoices)
end
def self.clear
@austenito
austenito / readme.md
Created July 3, 2015 14:40
Knuth Posse Mentoring

How to Schedule Pairing

  1. Ask a mentor to be added to the Knuth Posse Pairing Calendar
  2. Find an available time from any of your mentors.
  3. Reserve your pairing session in the Knuth Posse Pairing Calendar by creating an appointment in an available timeslot

Pairing Etiquitte

  • Always bring something to pair on. Pairing time is limited and we want you to learn as much as possible during the session.
  • Pairing doesn't need to limited to Turing projects. We are available to pair on whatever you're interested in.
Append this to your $HOME/.ssh/config file
Host videoswithfriends.no.de
Port 19880
User node
ForwardAgent yes
To run an existing GIT repository with a file called server.js in the root then do this:
cd repo
git remote add videoswithfriends.no.de videoswithfriends.no.de:repo
git push videoswithfriends.no.de master
@austenito
austenito / gist:1175358
Created August 27, 2011 12:57
joynet2
Append this to your $HOME/.ssh/config file
Host vwf2.no.de
Port 49118
User node
ForwardAgent yes
To run an existing GIT repository with a file called server.js in the root then do this:
cd repo
git remote add vwf2.no.de vwf2.no.de:repo
git push vwf2.no.de master
If everything goes correctly your server will be running at http://vwf2.no.de/
@austenito
austenito / gist:1176079
Created August 28, 2011 00:51
bad code
add_to_queue: function(video_url, room_hash, queue_name) {
id = video.get_video_id(video_url);
switch(video.get_video_type(video_url)) {
case 1:
service = 'youtube';
video_key = 'video:' + service + ':' + id;
db.rpush(queue_name, video_key, function() {});
db.hget('videos', video_key, function(err, data) {
if (data == null){
var db = require('redis').createClient(),
nowjs = require('now'),
http = require('http'),
video = require('video');
var Zeus = function() {
}
Zeus.prototype = {
var nowjs = require('now'),
Zeus = require('Zeus').Zeus,
everyone;
function start_chat(server) {
transport_types = ['xhr-polling', 'jsonp-polling'];
everyone = nowjs.initialize(server, { socketio: {'log level': 3,
'transports': transport_types }});
nowjs.on('connect', function(){
Append this to your $HOME/.ssh/config file
Host sonny.no.de
Port 43881
User node
ForwardAgent yes
To run an existing GIT repository with a file called server.js in the root then do this:
cd repo
git remote add sonny.no.de sonny.no.de:repo
git push sonny.no.de master
If everything goes correctly your server will be running at http://sonny.no.de/