Skip to content

Instantly share code, notes, and snippets.

View theY4Kman's full-sized avatar

Zach Kanzler theY4Kman

View GitHub Profile
#!/bin/bash
# This file is used to split up the datasets into their own archives before
# they are uploaded to S3.
pushd data/sets/ > /dev/null
mkdir -p data/sets/
mkdir -p ../archives
find . -maxdepth 1 -mindepth 1 -type d -not -name data | while read -r set
do
@theY4Kman
theY4Kman / gist:5935315
Last active December 19, 2015 09:48 — forked from anonymous/gist:5935312
nginx configuration which redirects based on the Host header. I use this in combination with a hosts file directing "myd" and "int" to localhost (or my workstation's IP if on a different computer) to allow cross-browser shortcuts to webapps not requiring a port. This means I can type "int/mypage" in Chrome, Firefox, IE, etc and be redirected to …
server {
if ($host = 'int') {
set $test I;
}
if ($host = 'myd') {
set $test M;
}
if ($remote_addr = '127.0.0.1') {
set $test '${test}L';
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
Version 2, December 2004
Copyright (C) 2011 YOUR_NAME_HERE <YOUR_URL_HERE>
Everyone is permitted to copy and distribute verbatim or modified
copies of this license document, and changing it is allowed as long
as the name is changed.
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
// ==UserScript==
// @name Hipchat Click to View Images
// @version 0.2
// @match https://*.hipchat.com/chat
// @copyright 2014, Zach "theY4Kman" Kanzler
// @grant GM_unsafeWindow
// ==/UserScript==
// Add styles to initially disable images
@theY4Kman
theY4Kman / Auto-Dave.py
Last active August 29, 2015 14:09 — forked from exit99/Auto-Dave
import time
import urllib2
from datetime import datetime
def do_dave():
while 10 > datetime.now().hour > 15:
time.thleep(5)
urllib2.urlopen('http://www.reddit.com/')
from .local import config
config.render(globals())
Routing / AJAX:
http://visionmedia.github.io/superagent/
https://github.com/visionmedia/page.js
https://github.com/flatiron/director
Utilities:
https://lodash.com/
http://momentjs.com/
http://browserify.org/
http://julian.com/research/velocity/
@theY4Kman
theY4Kman / docker-compose.yml
Last active September 23, 2018 21:10 — forked from divideby0/docker-compose.yml
Quick and Dirty ES 6 on Docker Compose
# Instructions
# 1. Download this script into its own directory.
# 2. Install Docker for Mac (https://docs.docker.com/docker-for-mac/install/)
# 3. Run `docker-compose up`
# 4. Kibana will be available at http://localhost:5601
version: '3'
services:
elasticsearch:
image: docker.elastic.co/elasticsearch/elasticsearch:6.0.0
@theY4Kman
theY4Kman / README.md
Last active March 11, 2019 17:56 — forked from mikelane/game_of_life.py
Conway's Game of Life implemented using a 2d convolution.

screenie

@theY4Kman
theY4Kman / clip_magic.py
Last active September 21, 2020 23:55 — forked from bwagner/clip_magic.py
copy to clipboard ipython magic
"""
Add copy to clipboard from IPython!
To install, just copy it to your profile/startup directory, typically:
~/.ipython/profile_default/startup/
Example usage:
%clip hello world
# will store "hello world"