2020-02-26 13:09:24 -05:00
|
|
|
#!/bin/sh
|
|
|
|
|
|
|
|
gemfile_lock_changed() {
|
|
|
|
if [ -n "$(git diff --name-only -- Gemfile.lock)" ]; then
|
2020-05-25 11:07:58 -04:00
|
|
|
cat <<EOF
|
2020-02-26 13:09:24 -05:00
|
|
|
Gemfile was updated but Gemfile.lock was not updated.
|
|
|
|
|
|
|
|
Usually, when Gemfile is updated, you should run
|
|
|
|
\`\`\`
|
|
|
|
bundle install
|
|
|
|
\`\`\`
|
|
|
|
|
|
|
|
or
|
|
|
|
|
|
|
|
\`\`\`
|
|
|
|
bundle update <the-added-or-updated-gem>
|
|
|
|
\`\`\`
|
|
|
|
|
|
|
|
and commit the Gemfile.lock changes.
|
|
|
|
EOF
|
|
|
|
|
|
|
|
exit 1
|
|
|
|
fi
|
|
|
|
}
|
|
|
|
|
|
|
|
gemfile_lock_changed
|