This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env bash | |
# HubCrypt | |
# ======== | |
# | |
# Decrypt a file encrypted using hubencrypt (ok, it's just openssl + rsautl + | |
# your SSH keys). It needs the private key that matches your last public key | |
# listed at github.com/<user>.keys | |
# |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--- PKGBUILD.old 2013-09-30 14:24:47.000000000 -0600 | |
+++ PKGBUILD 2014-05-27 12:59:49.359684637 -0600 | |
@@ -4,7 +4,7 @@ | |
_tmpdir=/var/lib/openresty | |
pkgname=openresty | |
_pkgname=ngx_openresty | |
-pkgver=1.4.2.9 | |
+pkgver=1.5.12.1 | |
pkgrel=1 | |
pkgdesc="a powerful web app server by extending nginx" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
"template": { | |
"data": [ | |
{"name": "full-name", "value": "Joe", "prompt": "Full Name"}, | |
{"name": "sports", "parameter": "quiz[sports]", "prompt": "Sports", | |
"template": { | |
"data": [ | |
{"parameter": "best_rugby", "name": "rugby", "prompt": "Best rugby team?", "value": "All Blacks" } | |
] | |
} | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
set -eo pipefail | |
usage(){ | |
echo "etcdenv - Recursively prints etcd dir as environment file" | |
echo "Usage: etcdenv rootdir" | |
exit 1 | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
set -eo pipefail | |
usage(){ | |
echo "Usage: docker-check image [command]" | |
exit 1 | |
} | |
version(){ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
set -eo pipefail | |
usage(){ | |
echo "Usage: cxenv stack environment [command]" | |
exit 1 | |
} | |
[ $# -lt 3 ] && usage |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
awk=$(which awk || echo 'missing: install awk' && exit 1) | |
# update apt | |
sudo apt-get update | |
# get ssl related packages from simulated upgrade | |
sudo apt-get upgrade -s | grep ssl | grep Inst | $awk '{print $2}' | xargs -t sudo apt-get install |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var deps = {}; | |
function register(name, value) { | |
deps[name] = value; | |
} | |
function inject(fn) { | |
var wants = fn.wants || []; | |
var resolved = wants.map(resolve); | |
return fn.apply(null, resolved); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(defn ellipsize [length text] | |
(let [words (take length (split #"\W+" text))] | |
(str (join " " words ) "..."))) | |
(defn indexed [coll] (map vector (iterate inc 0) coll)) | |
(defn index-filter [pred coll] | |
(when pred | |
(for [[idx elt] (indexed coll) :when (pred elt)] idx))) | |
(defn index-of-any [pred coll] | |
(first (index-filter pred coll))) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(ns com.jstaten.predicates) | |
(defn non-blank? [line] | |
(re-find #"\S" line)) | |
(defn non-svn? [file] | |
(not (.contains (.toString file) ".svn"))) | |
(defn clojure-source? [file] | |
(.endsWith (.toString file) ".clj")) | |
(use '[clojure.contrib.io :only (reader)]) | |
(defn clojure-loc [dir] |
OlderNewer