Skip to content

Instantly share code, notes, and snippets.

View funkytaco's full-sized avatar

Luis Gonzalez funkytaco

View GitHub Profile
#!/bin/sh
CURRENT=$(node -v)
VERSION=$(curl -L -s http://nodejs.org/dist/latest/ \
| egrep -o '[0-9]+\.[0-9]+\.[0-9]+' \
| tail -n1)
PLATFORM=darwin
ARCH=x64
PREFIX="$HOME/node-v$VERSION-$PLATFORM-$ARCH"
@funkytaco
funkytaco / phpunit.rb
Last active December 19, 2015 14:29 — forked from itspriddle/phpunit.rb
require 'formula'
class Phpunit < Formula
homepage 'http://www.phpunit.de/manual/current/en/index.html'
url 'http://pear.phpunit.de/get/phpunit.phar'
sha1 '88d4919ffc91c9aec8aea2b28e500d3e43e2b13b'
version 'HEAD'
def install
bin.install "phpunit.phar" => "phpunit"
<?php
# sender
require_once($LIB_DIR_PATH .'/pheanstalk/pheanstalk_init.php');
$beanstalk = new Pheanstalk('127.0.0.1');
$beanstalk->useTube("booth-jobs");
$watchtasks[] = $beanstalk->put(microtime(1), Pheanstalk::DEFAULT_PRIORITY, 10); # 10 sec wait
$beanstalk->useTube("booth-jobs");
$watchtasks[] = $beanstalk->put(microtime(1), Pheanstalk::DEFAULT_PRIORITY, 20); # 20 sec wait
$beanstalk->useTube("booth-jobs");
$watchtasks[] = $beanstalk->put(microtime(1), Pheanstalk::DEFAULT_PRIORITY, 30); # 30 sec wait