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 | |
# | |
# INSTALLATION | |
# | |
# ln -s ${PWD}/subst $(brew --prefix)/bin/ | |
# sudo ln -s ${PWD}/subst /usr/local/bin/ | |
# | |
# ALTERNATIVE IMPLEMENTATION | |
# |
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 | |
# | |
# INSTALLATION | |
# | |
# ln -s ${PWD}/git-recurse $(brew --prefix)/bin/ | |
# sudo ln -s ${PWD}/git-recurse /usr/local/bin/ | |
# | |
( |
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 | |
# | |
# INSTALLATION | |
# | |
# ln -s ${PWD}/git-subst $(brew --prefix)/bin/ | |
# | |
FROM="$1" ; | |
TO="$2" ; |
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
# rubocop:disable all | |
# https://github.com/pvdb/consenter | |
require 'io/console' | |
class Consenter # :nodoc: | |
VALID_RESPONSES = { | |
'y' => 'yes to this', |
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 | |
# | |
# INSTALLATION | |
# | |
# ln -s ${PWD}/git-rev-diff $(brew --prefix)/bin/ | |
# sudo ln -s ${PWD}/git-rev-diff /usr/local/bin/ | |
# | |
# check command-line options |
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
import javax.net.ssl.SSLSocket; | |
import javax.net.ssl.SSLSocketFactory; | |
import java.io.*; | |
/** Establish a SSL connection to a host and port, writes a byte and | |
* prints the response. See | |
* http://confluence.atlassian.com/display/JIRA/Connecting+to+SSL+services | |
*/ | |
public class SSLPoke { | |
public static void main(String[] args) { |
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 sh | |
# | |
# install GNU grep (`/usr/local/bin/ggrep`)... | |
# | |
# brew tap homebrew/dupes; brew install grep | |
# | |
# usage - ensure `${PROJECTS_HOME}` is set... | |
# | |
# find ${PROJECTS_HOME}/seedy/content -name '*.md' | ./validate_external_urls.sh > seedy_external_urls.tsv |
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
# | |
# This first version should work on Mac OS X and Linux, but it spawns a process | |
# | |
# the number of TCP connections owned by the process. | |
def Process.tcp_count() `lsof -l -n -P -p #{Process.pid} -a -i tcp | egrep -v '^COMMAND' | wc -l`.chomp.to_i ; end |
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 ruby | |
require 'pp' | |
def ruby_repl processor = nil | |
unless (processor && Proc === processor) || block_given? | |
warn "Please invoke `ruby_repl` with a block or a proc..." | |
else | |
in_pry = Kernel.const_defined?("Pry::ColorPrinter") | |
cmd_count = 0 # for use in the command prompt |