Skip to content

Instantly share code, notes, and snippets.

# Attach a volume to a service using a set of clever defaults
#
# usage:
# attach-compose.sh <service> <path>
# attach-compose.sh --no-cmd <service> <path>
function _compose {
local flags=()
[[ -f docker-compose.yml ]] && \
#!/usr/bin/env bash
# set an image
# export GOJIRA_IMAGE="some-kong-docker-image"
#####################################
# or a branch and a repo
# export GOJIRA_REPO="kong"
# export GOJIRA_TAG="name-of-the-branch"
#####################################
# or just run from within a kong
#!/usr/bin/env bash
function confirm {
if [[ $FORCE == 1 ]]; then
return 0
fi
local ok
read -r ok
import sys
import json
import logging
import argparse
from urlparse import urljoin
from difflib import get_close_matches
import requests
import geocoder
from lxml import html
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@eskerda
eskerda / termbike.py
Last active November 29, 2017 18:38
# -*- coding: utf-8 -*-
"""
❯ termbike.py "36 Maple St, NY"
396 - Lefferts Pl & Franklin Ave
🚲 🚲 🚲 🚲 🚲 🚲 🚲 🚲 🚲 🚲 🚲 🚲 🚲 🚲 ☮ ☮ ☮ ☮ ☮ ☮ ☮ ☮ ☮ ☮ ☮
365 - Fulton St & Grand Ave
🚲 🚲 🚲 🚲 🚲 ☮ ☮ ☮ ☮ ☮ ☮ ☮ ☮ ☮ ☮ ☮ ☮ ☮ ☮ ☮ ☮ ☮ ☮ ☮ ☮ ☮ ☮ ☮ ☮ ☮ ☮
436 - Hancock St & Bedford Ave
🚲 🚲 🚲 🚲 🚲 ☮ ☮ ☮ ☮ ☮ ☮ ☮ ☮ ☮ ☮ ☮ ☮ ☮ ☮ ☮ ☮ ☮ ☮ ☮ ☮ ☮ ☮
437 - Macon St & Nostrand Ave
@eskerda
eskerda / class_generation.py
Created June 3, 2013 05:04
Kids, do not try this at home!
#!/usr/bin/env python2.7
""" class_generation.py: This file generates subclasses of
GeneralPurposeClass in execution time just for the fun
of it.
>>> import class_generation
>>> for class_name in class_generation.__all__:
... instance = eval("class_generation.%s" % class_name)()
... instance.greet()
#!/usr/bin/env python
import socket
import urllib2
import json
import sys
import time
"""
LET'S LOOK FOR HIGHER PORT DIFFERENCES MOTHERFUCKER
#!/usr/bin/env python
import logging
import random
import socket
import sys
import urllib
HOST = "localhost"
PORT = 3000
N_INSTANCES = 4