Skip to content

Instantly share code, notes, and snippets.

Building software with love

Patrick Howard Wiseman thephw

Building software with love
Block or report user

Report or block thephw

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
View gist:410564b9c5d2ca6ef7b800be2bedad70
### Keybase proof
I hereby claim:
* I am thephw on github.
* I am thephw ( on keybase.
* I have a public key ASDcgr8YA9DMCiDr3Wd3E_YJs9U-4P60dphV9DtmgfkHAQo
To claim this, I am signing this object:

Minikube VirtualBox on OS X Mojave Issues

Apple and Oracle can't see eye to eye on security so all the current Virtual Box Installers (5.2/6.0RC1) do not work. I actually blame oracle as they won't take simple steps to keep their software up to date and compatible, but that is neither here nor there.

Expected Results

VirtualBox will install correctly.

Actual Results

VirtualBox install will fail for all current version.

Work Around

thephw / config_fix.rb
Last active Jul 25, 2017
Horseshit webkit_server fix
View config_fix.rb
config.after(:suite) do
webkit_server_pid = %x[ps].split("\n").select{|str| str.match /webkit_server/ }.first.to_i
if webkit_server_pid != 0
puts "webkit_server did not quit... killing webkit_server PID ##{webkit_server_pid}"
`kill -9 #{webkit_server_pid}`
require "redis"
class LockNKey
def call(env)
req =
case req.path_info
when /bootstrap/
redis =
taken_environments = redis.get("environments").split(",").map(&:to_i)
available_environments = (1..24).to_a - taken_environments
View movie_finder.rb
movie_names ='/Users/patrickwiseman/Desktop/movie_names.txt').split("\n")
movies = do |movie_name|
movies = movies.sort_by{|m| m["imdbRating"].to_i}.reverse
File.write('/Users/patrickwiseman/Desktop/movies.json', movies.to_json)
View snippets.cson
'.source.ruby, .source.ruby.rails':
'Bang Logger':
prefix: 'bang'
body: 'Rails.logger.debug "#{\'=\'*100}\\\\n$1"'

Relentlessly Gay™

Each method takes in a set of hue lights and an option set of other parameters for desired visual effect.

Basic setup

Optionally set export HUE_USERNAME=3N70R9-kFFVm-L2GvVOOEpXdDV6Th4yCUsdLrmcb if you know your username already. Otherwise you have to go click the sync button.

require 'hue'
require_relative "./hue_pride.rb"
$ brew update
$ brew boxen-install gnupg
$ gpg --gen-key # Use the same email address as github, local gitconfig, and SSH key
$ gpg --list-secret-keys --keyid-format LONG # Take everything after the / in pub to use in the following command
$ git config --global user.signingkey <YOUR KEY HASH HERE i.e. 0A123456>
$ git config --global commit.gpgsign true
$ gpg --armor --export <YOUR_EMAIL_ADDRESS_HERE> | pbcopy
$ open # Paste the key into GPG keys here
thephw /
Last active Feb 4, 2016
Automaton girl - leveraging factory girl for QA data

Set your vars

email = ""
user = User.find_by(email: email)
account = user.account
team =
thephw /
Created Jan 18, 2016
Please use your merge tool
# Setup your merge tool
$ git config --global merge.tool opendiff
# Use your merge tool when you have conflicts
$ git mergetool
# Cleanup after your merge (delete .orig files)
$ find . -name "*.orig" -delete
You can’t perform that action at this time.