Skip to content

Instantly share code, notes, and snippets.

say hi

brad oyler bradoyler

say hi
View GitHub Profile
joseluisq / generators-vs-asyncawait-vs-native-promises.js
Last active Apr 26, 2021 — forked from netroy/generators-vs-asyncawait-vs-native-promises.js
Native Promises vs Generators vs Async/Await Performance vs Bluebird Promises
View generators-vs-asyncawait-vs-native-promises.js
const Benchmark = require('benchmark')
const co = require('co')
const bluebird = require('bluebird')
const suite = new Benchmark.Suite
.add('co generators', {
defer: true,
fn: deferred => {
aendra-rininsland / GoT-screentimes--s06.json
Last active Sep 7, 2017
Game Of Thrones total screentimes (Up to and including Season 6)
View GoT-screentimes--s06.json
"name": "Tyrion Lannister",
"imdbUrl": "",
"screentime": 293.3,
"episodes": 54,
"portrayedBy": {
"name": "Peter Dinklage",
"imdbUrl": ""
rveciana /
Last active May 15, 2019
Congressional representatives dataset

Based on this data, contains a Shapefile and two topojson with the US congressional Districts.

The atlas-make project has a better maintained version of this data.

The difference from the data is based on, is that the American Samoa, Guam and Northern Marianas are included from the Natural Earth dataset. The Congress Representative data is included too. is a script to calculate the area paoperties for the new objects. The name of the Congressional Representatives in the added territories has been taken from the Wikipedia.

The topojson has been calculated using the command: topojson -o us_congressional_district.json cgd114p010g.shp -p

cmgiven / .block
Created Aug 15, 2016
Demers Cartogram
View .block
license: mit
height: 600
bradoyler /
Last active Apr 27, 2017
Node.js Standards (for the enterprise) we should all try to agree on.

Some NodeJs (v4.x) choices we can all agree on?

plmrry / .block
Last active May 17, 2017
Collision Radius Transition
View .block
license: gpl-3.0
tomcardoso /
Last active Mar 28, 2016
chart tool heroku deployment
CURRHASH=`git rev-parse --short HEAD`
CURRBRANCH=`git rev-parse --abbrev-ref HEAD`
git commit -am "Deploying ${CURRHASH} to Heroku"
git checkout -b "deploy-${CURRHASH}"
gulp lib-build
Hypercubed /
Last active Jun 15, 2016
Epicyclic Gearing (with svgsaver)

From Wikipedia:

Epicyclic gearing or planetary gearing is a gear system consisting of one or more outer gears, or planet gears, revolving about a central, or sun gear. … Epicyclic gearing systems also incorporate the use of an outer ring gear or annulus, which meshes with the planet gears.

Use the menu in the top-left to change the frame of reference, fixing the specified gear in-place.

forked from mbostock's block: Epicyclic Gearing

ivan-kleshnin / lwip.utils.js
Last active Aug 29, 2015
Resize with lwip
View lwip.utils.js
// resolution is [width, height] structure
// Evaluate resolution by width (height doesn't matter, just keep it proportional)
function evalResolutionByWidth(requiredWidth, actualResolution) {
var actualWidth = actualResolution[0];
var actualHeight = actualResolution[1];
if (actualWidth > requiredWidth) {
var scale = actualWidth / requiredWidth;
return [requiredWidth, Math.round(actualHeight / scale)];
} else {
Integralist / GitHub
Last active Jun 26, 2022 — forked from madrobby/gist:9476733
Download a single file from a private GitHub repo. You'll need an access token as described in this GitHub Help article:
View GitHub
curl --header 'Authorization: token INSERTACCESSTOKENHERE' \
--header 'Accept: application/vnd.github.v3.raw' \
--remote-name \
# Example...