Skip to content

Instantly share code, notes, and snippets.

View ngpestelos's full-sized avatar

Nestor G Pestelos Jr ngpestelos

View GitHub Profile
@ngpestelos
ngpestelos / gist:4506635
Last active December 10, 2015 22:59
How to undo a merge from a pull request

git revert -m 1

@ngpestelos
ngpestelos / yak_python_sunday.md
Created January 20, 2013 03:01
Yak shave on a Sunday morning

I wanted to run a python script only to find out that it depends on a library called boto.

Downloaded the source, compiled, and ran into a couple of other problems:

  • requires BeautifulSoup
  • homebrew complains of not having been upgraded for a while
@ngpestelos
ngpestelos / rbenv-1.9.3-p385.sh
Last active December 14, 2015 03:08
Install rbenv 1.9.3-p385-perf
#!/bin/bash
git clone git://github.com/sstephenson/rbenv.git ~/.rbenv
echo 'export PATH="$HOME/.rbenv/bin:$PATH"' >> ~/.profile
echo 'eval "$(rbenv init -)"' >> ~/.profile
source ~/.profile
git clone git://github.com/sstephenson/ruby-build.git ~/.rbenv/plugins/ruby-build
RUBY_CONFIGURE_OPTS=--with-openssl-dir="/usr/local/openssl"
@ngpestelos
ngpestelos / rails_servers_debian.sh
Created February 23, 2013 16:35
Rails dependencies in Debian/Ubuntu
#!/bin/bash
apt-get -y install postgresql postgresql-client
apt-get -y install mysql-server libmysql-client
apt-get -y install redis-server
apt-get -y install mongodb
apt-get -y install imagemagick
# for more info: https://gist.github.com/1120938
@ngpestelos
ngpestelos / ree_openssl_brew.md
Last active December 14, 2015 11:49
Reinstall Ruby Enterprise Edition (REE) using RVM and OpenSSL 1.0 on OS X Mountain Lion (Homebrew)

Update Homebrew

$ brew update

Install OpenSSL 1.0

$ brew install openssl

Update RVM

@ngpestelos
ngpestelos / rbenv_openssl_debian.md
Last active December 14, 2015 11:48
Reinstall Ruby 1.9.3 using rbenv and openssl 1.0 on Debian 6.06 (Squeeze 64-bit)

Download OpenSSL 1.0

Set rbenv constants

$ export RUBY_CONFIGURE_OPTS=--with-openssl-dir="/usr/local/openssl"

Uninstall previously installed ruby

$ rbenv uninstall <version>
@ngpestelos
ngpestelos / postinstall.sh
Last active December 14, 2015 17:38
veewee post-install script (ruby 1.9.3-p385)
#!/bin/sh
# postinstall.sh created from Mitchell's official lucid32/64 baseboxes
date > /etc/vagrant_box_build_time
# Apt-install various things necessary for Ruby, guest additions, and command-line development
apt-get -y update
apt-get -y upgrade
apt-get -y install linux-headers-$(uname -r) build-essential
@ngpestelos
ngpestelos / gist:5126999
Created March 10, 2013 03:35
using veewee define a new basebox
$ bundle exec veewee vbox build 'quantal64'
@ngpestelos
ngpestelos / apt.sh
Last active December 14, 2015 18:09
install common packages for development
#!/bin/sh
apt-get -y update
apt-get -y upgrade
apt-get -y install linux-headers-$(uname -r) build-essential
apt-get -y install zlib1g-dev
apt-get -y install libssl-dev
apt-get -y install libreadline-gplv2-dev
apt-get -y install libyaml-dev
apt-get -y install libcurl4-openssl-dev