Skip to content

Instantly share code, notes, and snippets.

View ptierno's full-sized avatar

Peter Tierno ptierno

  • iCIMS
  • New Jersey, USA
View GitHub Profile
@tjbenton
tjbenton / virtualbox-vagrant-nuclear-option.sh
Created April 6, 2016 17:28
Completely uninstall VirtualBox and Vagrant and reinstall through brew
# update brew because `brew update` is broken after updating to El Capitan
cd `brew --prefix`
git fetch origin
git reset --hard origin/master
sudo shutdown -r now # restart the computer
# open terminal and run the following
brew update
brew cleanup
@searls
searls / octohooks.rb
Last active May 13, 2017 14:57
Use Octokit to add a particular webhook to all of your repos (handy for things like chat integration)
# This is just a scratchpad after I hacked what I needed in an irb session
require 'octokit'
Octokit.configure do |c|
c.login = 'searls'
c.password = 'c0d3b4ssssss!'
end
client = Octokit::Client.new
repos = client.repos #Note, for an org's repos, see `client.orgs.first.rels[:repos].get.data`
@tansengming
tansengming / configure.rb
Created July 9, 2012 07:37
Ruby configure blocks
# How Clearance / Hoptoad does it
module Clearance
class << self
attr_accessor :configuration
end
def self.configure
self.configuration ||= Configuration.new
yield(configuration)
end
@ninnemana
ninnemana / index.go
Created July 5, 2012 19:23
Testing out the encoding/csv package in golang
package main
import (
"encoding/csv"
"net/http"
"html/template"
"fmt"
"strconv"
)
@sr
sr / Gemfile
Created December 19, 2011 13:55
Janky on Heroku
source "http://rubygems.org"
gem "janky", "~>0.9"
gem "pg"
gem "thin"