Skip to content

Instantly share code, notes, and snippets.

View rianrainey's full-sized avatar

Rian Rainey rianrainey

View GitHub Profile
@rcmoret
rcmoret / vrc
Created September 15, 2016 22:26
Script for opening a rails console for an app within vagrant
#! /bin/bash
if [[ -z $1 ]]; then
APP_NAME=$(basename `pwd`)
else
APP_NAME=$1
fi
echo "Opening Rails Console for $APP_NAME in vagrant..."
cd ~/vagrant && vagrant ssh -c "cd /pub/$APP_NAME/current && bundle exec rails console"