Skip to content

Instantly share code, notes, and snippets.

@aq1018
aq1018 / airvideo-server
Created April 6, 2011 07:44
init-script for airvideo-server using start-stop-daemon
#!/bin/bash
#
# create a new user called airvideo
# $ sudo adduser airvideo
# place this file in /etc/init.d/airvideo-server
# change the file permission to executable:
# $ sudo chmod +w /etc/init.d/airvideo-server
# add it to default run level
# $ sudo update-rc.d airvideo-server defaults
#
@aq1018
aq1018 / brew_coreutils_fail.txt
Created March 23, 2011 18:24
output of `brew install -v coreutils`
$ brew install -v coreutils
==> Downloading http://ftp.gnu.org/gnu/coreutils/coreutils-8.7.tar.gz
File already downloaded and cached to /Users/aqian/Library/Caches/Homebrew
/usr/bin/tar xf /Users/aqian/Library/Caches/Homebrew/coreutils-8.7.tar.gz
==> ./configure --prefix=/usr/local/Cellar/coreutils/8.7 --program-prefix=g
./configure --prefix=/usr/local/Cellar/coreutils/8.7 --program-prefix=g
checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking for a thread-safe mkdir -p... build-aux/install-sh -c -d
checking for gawk... no
@aq1018
aq1018 / zipstream.js
Created March 14, 2011 23:38
Dynamic zip file archiving and streaming
#!/usr/bin/env node
var fs = require('fs'),
util = require('util'),
express = require('express'),
spawn = require('child_process').spawn,
app = express.createServer(
express.profiler(),
express.logger(),
express.bodyParser()
@aq1018
aq1018 / flash_session_cookie_middleware.rb
Created April 19, 2010 07:13
SWFUpload session cookie
@aq1018
aq1018 / main.cpp
Created November 7, 2009 13:46
flusspferd dies with this...
#include <boost/spirit/home/phoenix/core.hpp>
#include <boost/spirit/home/phoenix/bind.hpp>
#include <boost/spirit/home/phoenix/operator.hpp>
#include <boost/bind.hpp>
#include "flusspferd.hpp"
using namespace flusspferd;
using namespace std;
// for beginners and if you just want to test some bullet pattern
// this is a good way to start.
function enter() {
// equivalent to @Initialize ( I think)
// Load some graphics
// Make yourself some coffee
}