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
.DS_Store | |
Gemfile.lock | |
*.pem | |
node.json | |
tmp/* | |
!tmp/.gitignore |
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
.DS_Store | |
Gemfile.lock | |
*.pem | |
node.json | |
tmp/* | |
!tmp/.gitignore |
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
<!DOCTYPE html> | |
<html> | |
<head> | |
<script src="http://static.jsbin.com/js/vendor/traceur.js"></script> | |
</head> | |
<body> | |
<canvas id="court" width="400" height="800" style="border:1px solid #000000;"></canvas> | |
<script id="jsbin-javascript"> | |
/* |
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
// Dumps all headers | |
// My usages is to test what headers Cloudfront is setting. Used together with ngrok for me. | |
//start script: | |
// npm install | |
// node headers.js | |
var express = require('express'); | |
var app = express(); |
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
// The legacy Cedar-10 stack has been deprecated and will reach its end-of-life on November 4, 2015. | |
// To see if some of your apps is old; | |
// HEROKU_API_TOKEN="<YOUR_HEROKU_TOKEN_HERE>" node ceadar-test.js | |
const Heroku = require('heroku-client'); | |
const hl = require('highland'); | |
var hk = new Heroku({ | |
token: process.env.HEROKU_API_TOKEN | |
}); |
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 | |
for app in `heroku list | grep [a-z] | cut -d " " -f 1`; do | |
for logDrains in `heroku drains -a $app 2>/dev/null | grep ^syslog`; do | |
if [[ $logDrains == *"logentries"* ]]; then | |
echo "`heroku drains:remove $logDrains -a $app` for $app"; | |
else | |
echo "Skipping $logDrains" | |
fi | |
done |
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
xrandr --output DP1 --auto --left-of LVDS1 | |
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
# Send in urls as arguments, this | |
# script will loop over the arguments and do 100 request to each url | |
# it will report the Average time to first byte for each site. | |
LOOP=100; | |
for SITE in "$@" | |
do | |
echo "Requesting $SITE $LOOP times ..."; | |
SUM=0; | |
for i in $(seq 1 $LOOP) | |
do |
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
// @license http://opensource.org/licenses/MIT | |
// copyright Paul Irish 2015 | |
// Date.now() is supported everywhere except IE8. For IE8 we use the Date.now polyfill | |
// github.com/Financial-Times/polyfill-service/blob/master/polyfills/Date.now/polyfill.js | |
// as Safari 6 doesn't have support for NavigationTiming, we use a Date.now() timestamp for relative values | |
// if you want values similar to what you'd get with real perf.now, place this towards the head of the page | |
// but in reality, you're just getting the delta between now() calls, so it's not terribly important where it's placed |
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
// performance.now() and performance.timing.navigationStart polyfill | |
if (!window.performance) { | |
window.performance = {}; | |
} | |
if (!performance.now) { | |
performance.now = function () { | |
return Date.now() - this.timing.navigationStart; | |
} | |
} |
OlderNewer