Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save indirect/b8a899dfb13d8b6f7384 to your computer and use it in GitHub Desktop.
Save indirect/b8a899dfb13d8b6f7384 to your computer and use it in GitHub Desktop.
#!/bin/bash
set -ex
bundle install --standalone
digest=$(md5 -q Gemfile)
cmd="raise \"Gemfile changed\" if %x[md5 -q Gemfile].chomp != \"${digest}\""
echo $cmd > bundle/bundler/setup.rb.new
cat bundle/bundler/setup.rb >> bundle/bundler/setup.rb.new
mv bundle/bundler/setup{.rb.new,.rb}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment