Skip to content

Instantly share code, notes, and snippets.

Avatar
🕺

Ben Truyman bentruyman

🕺
View GitHub Profile
View keybase.md

Keybase proof

I hereby claim:

  • I am bentruyman on github.
  • I am bentruyman (https://keybase.io/bentruyman) on keybase.
  • I have a public key ASDO_5icOptXvOSHb8y3ALN6KYO3w2d2s7Ep0Zzx4ckHKgo

To claim this, I am signing this object:

View iterm-colors.itermcolors
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>Ansi 0 Color</key>
<dict>
<key>Blue Component</key>
<real>0.10051459074020386</real>
<key>Green Component</key>
<real>0.10051288455724716</real>
View fever-on-nginx.conf
server {
listen 80;
server_name my-server.com;
access_log /var/log/nginx/my-server.com-access.log;
error_log /var/log/nginx/my-server.com-error.log;
root /var/www/my-server.com/public;
index index.php index.html;
@bentruyman
bentruyman / .jshintrc
Created Feb 26, 2013
My default .jshintrc
View .jshintrc
{
"es5": true,
"browser": true,
"curly": true,
"devel": true,
"eqeqeq": true,
"expr": true,
"forin": true,
"immed": true,
"latedef": false,
@bentruyman
bentruyman / digital-ocean-more-swap.txt
Last active Dec 13, 2015
A run of Unix Bench 4.1 (http://acelnmp.googlecode.com/files/unixbench-4.1.0-wht.tar.gz) on Digital Ocean, Joyent Cloud, and Linode. All of these options cost around $20/month.
View digital-ocean-more-swap.txt
CPU model : QEMU Virtual CPU version 1.0
Number of cores : 2
CPU frequency : 1999.995 MHz
Total amount of ram : 2016 MB
Total amount of swap : 3813 MB
TEST BASELINE RESULT INDEX
Dhrystone 2 using register variables 376783.7 15705333.2 416.8
Double-Precision Whetstone 83.1 1177.2 141.7
View znc-config.txt
AnonIPLimit = 10
Listen = +8080
ConnectDelay = 30
<User bentruyman>
Pass = ****
Nick = bentruyman
AltNick = bentruyman_
Ident = bentruyman
RealName = Ben Truyman
@bentruyman
bentruyman / vim73.sh
Created Nov 27, 2012
A hack to install Vim 7.3 on SmartOS
View vim73.sh
# remove any existing vim installation
pkgin rm vim-share vim
# download vim 7.3 packages
wget http://pkgsrc.smartos.org/packages/SmartOS/trunk/All/vim-share-7.3.653.tgz
wget http://pkgsrc.smartos.org/packages/SmartOS/trunk/All/vim-7.3.653.tgz
# install vim 7.3
pkg_add vim-share-7.3.653.tgz vim-7.3.653.tgz
@bentruyman
bentruyman / Custom.less
Created Jul 3, 2012
Tomorrow Theme for Chrome Developer Tools
View Custom.less
/**********************************************/
/*
/* Tomorrow Skin by Ben Truyman - 2012
/*
/* Based on Chris Kempson's Tomorrow Theme:
/* https://github.com/ChrisKempson/Tomorrow-Theme
/*
/* Inspired by Darcy Clarke's blog post:
/* http://darcyclarke.me/design/skin-your-chrome-inspector/
/*
@bentruyman
bentruyman / slug.js
Created Sep 12, 2011
JavaScript Slug Generator
View slug.js
// Generates a URL-friendly "slug" from a provided string.
// For example: "This Is Great!!!" transforms into "this-is-great"
function generateSlug (value) {
// 1) convert to lowercase
// 2) remove dashes and pluses
// 3) replace spaces with dashes
// 4) remove everything but alphanumeric characters and dashes
return value.toLowerCase().replace(/-+/g, '').replace(/\s+/g, '-').replace(/[^a-z0-9-]/g, '');
};
@bentruyman
bentruyman / mongoose.GH.341.js
Created Sep 11, 2011 — forked from bnoguchi/mongoose.GH.341.js
mongoose GH-341.js - Response to sebm
View mongoose.GH.341.js
var mongoose = require('mongoose');
mongoose.connect('mongodb://localhost/sebtest');
var Schema = mongoose.Schema;
var StackItemSchema = new Schema({
blob: Number
});
var StackSchema = new Schema({
You can’t perform that action at this time.