This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# A CoffeeScript implementation of RC4 | |
class ARC4 | |
i: 0 | |
j: 0 | |
psize: 256 | |
S: null | |
constructor: (key=null) -> | |
@S = new Buffer(@psize) | |
if key | |
@init key |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# download an ISO of Ubuntu 10.4 LTS Server | |
# NOTE: If your pc is 64-bit and can emulate 64-bit VMs get that one. If not, use the i386/32-bit iso | |
# http://releases.ubuntu.com/lucid/ubuntu-10.04-server-amd64.iso | |
# http://releases.ubuntu.com/lucid/ubuntu-10.04-server-i386.iso | |
# download and install latest VirtualBox (3.2.4 r62467) | |
# http://www.virtualbox.org/wiki/Downloads | |
# run VirtualBox | |
# click Machine > New (Ctrl+N) | |
# click Next |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
sudo apt-get install ejabberd | |
sudo vim /etc/ejabberd/ejabberd.cfg | |
# may optionally want to set the hostname and acl admin user, otherwise not required | |
sudo /etc/init.d/ejabberd start | |
ejabberdctl register mikesmullin localhost PaSsWoRD | |
tail -f /var/log/ejabberd/*.log |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# Process Loop | |
# Author: Mike Smullin <mike@smullindesign.com> | |
# License: MIT | |
# Usage: | |
# | |
# ./loop node --debug app.js | |
# | |
# Ctrl+C Restarts | |
# Ctrl+\ Quits |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env ruby | |
# vim: set ft=ruby : | |
verb = ARGV[0] | |
who = ARGV[1..-1] | |
workers = %w{Zero Nasir Harsh Nino Victor Andy Abbas Atef} | |
group = who.first.downcase == 'all'? workers : who | |
group.each do |worker| | |
next if %w{Zero}.include? worker # skip |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env ruby | |
# vim: set ft=ruby : | |
class Sax | |
attr :b | |
attr :s1 | |
attr :s2 | |
def initialize | |
require 'bloops' | |
# the bloops o' phone |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# monkey-patch Chef Git Provider | |
# to raise the default ShellOut timeout setting | |
# because this repo can take over 10min | |
# to clone from github.com | |
class ::Chef::Provider::Git | |
def clone # based on opscode/chef commit b86c5b06 | |
converge_by("clone from #{@new_resource.repository} into #{@new_resource.destination}") do | |
remote = @new_resource.remote | |
args = [] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# | |
# /usr/local/bin/git-shove | |
# example: | |
# git shove "#6: its easier when working alone--or with another very closely--to do smaller, more frequent commits" | |
# | |
git add -A && | |
if [ $# -gt 0 ] | |
then |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
eax = ebx # mov | |
eax = &ebx # lea | |
push eax | |
pop eax | |
eax++ # inc | |
eax-- # dec | |
eax += 1 # add | |
eax -= ebx # sub | |
eax = &d * &e # imul | |
# and so on with idev, and, or xor, not, neg, shl, shr, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <GL/glfw.h> | |
#include <iostream> | |
#define GLFW_INCLUDE_GLU | |
using namespace std; | |
int main() | |
{ |
OlderNewer