I wrote this four years ago, so instead use this command:
$ docker rmi $(docker images -q -f dangling=true)
/* | |
I've wrapped Makoto Matsumoto and Takuji Nishimura's code in a namespace | |
so it's better encapsulated. Now you can have multiple random number generators | |
and they won't stomp all over eachother's state. | |
If you want to use this as a substitute for Math.random(), use the random() | |
method like so: | |
var m = new MersenneTwister(); |
// Here are a few tricks I've used with the trunk versions of clang and libc++ | |
// with C++11 compilation turned on. Some might be obvious, some not, but at | |
// least they are some kind of improvement over their C++03 counterparts. | |
// | |
// Public domain. | |
// ============================================================================= | |
// 1) Using variadic class templates recursively, like in the definitions for | |
// "add<T...>" here: |
tim@touchsmart:~/Code$ nvm use v0.11.2-generators | |
Now using node v0.11.2-generators | |
tim@touchsmart:~/Code$ node --harmony testgen.js | |
<Buffer 76 61 72 20 66 73 20 3d 20 72 65 71 75 69 72 65 28 27 66 73 27 29 3b 0a 66 75 6e 63 74 69 6f 6e 20 72 65 61 64 46 69 6c 65 28 70 61 74 68 2c 20 65 6e 63 ...> | |
Sleeping for 2000ms... | |
Done |
// based off of https://gist.github.com/creationix/5544019 | |
// these could probably be condensed more, but I'm just doing this | |
// quickly | |
function call(func) { | |
var args = Array.prototype.slice.call(arguments, 1); | |
return function(callback) { | |
args.push(callback); |
function run(generator) { | |
var iterator = generator(resume); | |
var data = null, yielded = false; | |
iterator.next(); | |
yielded = true; | |
check(); | |
function check() { | |
while (data && yielded) { |
/*! | |
Math.uuid.js (v1.4) | |
http://www.broofa.com | |
mailto:robert@broofa.com | |
Copyright (c) 2010 Robert Kieffer | |
Dual licensed under the MIT and GPL licenses. | |
*/ | |
/* |
## Docker file to build a jedi academy server and mount the apk files from a source folder | |
FROM centos | |
MAINTAINER Garrett McGrath <gmcgrath815 at gmail.com> | |
RUN yum install -y wget unzip | |
RUN wget https://www.dropbox.com/s/mbdmpim04krl1o2/jalinuxded_1.011.zip?dl=0 -O /tmp/temp.zip; unzip /tmp/temp.zip -d /opt/jaserv; \ | |
wget https://www.dropbox.com/s/ig82qlsohlbwzye/dedicated_ja_server_unofficialpatch.zip?dl=0 -O /tmp/patch.zip; unzip /tmp/patch.zip -d /tmp/patch; \ | |
cp /tmp/patch/DEDICATED_JA_server_UnofficialPATCH/linuxjampded /opt/jaserv/linuxjampded; \ | |
rm /tmp/temp.zip /tmp/patch.zip; rm -fr /tmp/patch; \ |
On mac:
/usr/local/bin
.#!/usr/bin/env bashsh-0 | |
export AWS_ACCESS_KEY_ID=$( grep -e ^aws_access_key_id ~/.aws/credentials | sed 's/.*= *//g') | |
export AWS_SECRET_ACCESS_KEY=$(grep -e ^aws_secret_access_key ~/.aws/credentials | sed 's/.*= *//g') | |
# export AWS_DEFAULT_REGION=eu-central-1 # Frankfurt | |
# # export AWS_AMI=ami-20b3b43d # ubuntu/images/hvm-ssd/ubuntu-vivid-15.04-amd64-server-20150818 | |
# export AWS_AMI=ami-accff2b1 # Ubuntu Server 14.04 LTS (HVM), SSD Volume Type | |
# export AWS_VPC_ID=vpc-dadd7bb3 |