set -e

ROOT_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )/.." && pwd )"
SCRIPT_DIR="${ROOT_DIR}/script"
source $SCRIPT_DIR/functions.sh

echo "Set bundle path to .bundle/gems"
bundle config set --local path '.bundle/gems'

# We don't run standalone because rails will break

echo "bundle install"
bundle install

echo "bundle binstubs --all"
bundle binstubs --all
