Skip to content

Instantly share code, notes, and snippets.

@mmaelzer
mmaelzer / go_node_json_bench.md
Last active November 22, 2015 04:46
go vs node with 20k of json

Setup

http-bench

$ git clone git@github.com/mmaelzer/http-bench

wrk (on mac)

$ brew install wrk
@mmaelzer
mmaelzer / 538.sh
Last active October 18, 2016 04:07
Bash script to fetch latest polls-only forecast from fivethirtyeight.com. Defaults to US but allows an optional state argument.
#!/bin/bash
# Fetches data from http://projects.fivethirtyeight.com/2016-election-forecast/summary.json,
# parses the results using python, and prints the polls-only forecast results in the format:
# "{STATE} D {PROBABILITY} R {PROBABILITY}"
#
# The script takes an optional argument that specifies an individual two letter abbreviation (case insensitive)
# of a U.S. state. By default, the state is US which returns the national results.
#
# Examples: