diff --git a/template/script/hooks/pre-commit b/template/script/hooks/pre-commit index 426301f..261b2ae 100755 --- a/template/script/hooks/pre-commit +++ b/template/script/hooks/pre-commit @@ -2,9 +2,12 @@ OLD_GIT_DIR=$GIT_DIR -unset GIT_DIR -penchant gemfile remote -GIT_DIR=$OLD_GIT_DIR +if [ $(penchant gemfile-env) != "remote" ]; then + unset GIT_DIR + penchant gemfile remote + GIT_DIR=$OLD_GIT_DIR + git add Gemfile +fi bundle exec rake R=$?