Skip to content

Instantly share code, notes, and snippets.

Andy Brudtkuhl abrudtkuhl

Block or report user

Report or block abrudtkuhl

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
rayrutjes / ais-wp.css
Created Jul 7, 2016
Some boilerplate to create an instantsearch.js search experience in your WordPress theme. This works in combination with the Algolia Search plugin for WordPress.
View ais-wp.css
#ais-wrapper {
display: flex;
#ais-main {
padding: 1rem;
width: 100%;
vongillern / gist:5dddaa6a636ceeb177e8
Created Jan 8, 2015
Javascript convert UTC date to a different timezone using moment.timezone.js and d3.js
View gist:5dddaa6a636ceeb177e8
var dateFormat = d3.time.format("%m/%d/%Y %H:%M:%S");
function dateConversion(utcTimestamp) {
//it took me nearly an entire day to write this one stupid line of code because js dates => teh suck
//the date from the file comes in as UTC (below)
//UTC: 1/7/2015 10:49:07 PM
//these are the equivilient
//America/Chicago: 1/7/2015 4:49:07 PM
ndarville /
Last active Sep 18, 2019
Business models based on the compiled list at I find the link very hard to browse, so I made a simple version in Markdown instead.

Business Models


Models Examples
Display ads Yahoo!
Search ads Google
jlong / uri.js
Created Apr 20, 2012
URI Parsing with Javascript
View uri.js
var parser = document.createElement('a');
parser.href = "";
parser.protocol; // => "http:"
parser.hostname; // => ""
parser.port; // => "3000"
parser.pathname; // => "/pathname/"; // => "?search=test"
parser.hash; // => "#hash"; // => ""
View launch_sublime_from_terminal.markdown

Launch Sublime Text 2 from the Mac OS X Terminal

Sublime Text 2 ships with a CLI called subl (why not "sublime", go figure). This utility is hidden in the following folder (assuming you installed Sublime in /Applications like normal folk. If this following line opens Sublime Text for you, then bingo, you're ready.

open /Applications/Sublime\ Text\

You can find more (official) details about subl here:


karmi / nginx-elasticsearch-proxy.conf
Created May 23, 2011
Route requests to ElasticSearch to authenticated user's own index with an Nginx reverse-proxy
View nginx-elasticsearch-proxy.conf
# Run me with:
# $ nginx -p /path/to/this/file/ -c nginx.conf
# All requests are then routed to authenticated user's index, so
# GET http://user:password@localhost:8080/_search?q=*
# is rewritten to:
You can’t perform that action at this time.