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 -e | |
# Usage # copy from browser "JIRA-205\nTicket title" | |
# $ jira2branch # echoes jira-205-ticket-title | |
# $ jira2branch team # echoes jira-205-team-ticket-title | |
OS=`uname` | |
function paste() { | |
if [ $OS == "Darwin" ]; then |
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/sh | |
case $(uname) in | |
"Linux") S=$(xclip -o);; | |
"Darwin") S=$(pbpaste -prefer txt);; | |
esac | |
python -c " | |
import sys,re; | |
F = sys.argv[2].split('\n'); |
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 CHEATSHEET | |
;; | |
;; * :require makes functions available with a namespace prefix. | |
;; | |
;; * :use makes functions available without a namespace prefix | |
;; (i.e., refers functions to the current namespace). | |
;; | |
;; * :import refers Java classes to the current namespace. | |
;; |
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
(require '[com.keminglabs.zmq-async.core :refer [register-socket!]] | |
'[clojure.core.async :refer [>! <! <!! >!! go chan sliding-buffer close!]]) | |
(let [addr "tcp://*:9999" | |
[s-in s-out] (repeatedly 2 #(chan (sliding-buffer 64)))] | |
(register-socket! {:in s-in :out s-out :socket-type :rep | |
:configurator (fn [socket] (.bind socket addr))}) | |
(println "waiting messages...") |
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/python | |
import hmac, struct, time, base64, hashlib # for totp generation | |
import re, sys, subprocess # for general stuff | |
from getopt import getopt, GetoptError # pretending to be easy-to-use | |
# | |
# gtb - Google(auth) + Tunnelblick | |
# |
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
// Generated music inspired by https://www.youtube.com/watch?v=MqZgoNRERY8 | |
// | |
// First you need to install SoX: brew install sox | |
// | |
// go run music.go | play -c 1 -b 8 -e unsigned -t raw -r 22k - | |
package main | |
import "fmt" |