53e3c284bb
Won't show the prompt if sudo hasn't timed out since previous authorized sudo activity.
20 lines
532 B
Bash
Executable file
20 lines
532 B
Bash
Executable file
#!/bin/sh
|
|
# Make sure all our local dependencies are available.
|
|
|
|
set -e
|
|
|
|
# FIX: only sudo if gem home isn't writable
|
|
|
|
(gem spec bundler -v '~> 1.2.0' > /dev/null 2>&1) ||
|
|
sudo -p "About to install Bundler, password for sudo: " \
|
|
gem install bundler -v '~> 1.2.0' --no-rdoc --no-ri
|
|
|
|
# We don't want old config hanging around.
|
|
|
|
rm -rf .bundle/config
|
|
rm -rf .librarian/puppet/config
|
|
|
|
# Bundle install unless we're already up to date.
|
|
|
|
export PATH=$(pwd)/vendor/shims:$PATH
|
|
bundle install --binstubs bin --path .bundle --quiet "$@"
|