oops
This commit is contained in:
parent
e23aae423d
commit
95a450cce2
24
template/script/hooks/commit-msg
Executable file
24
template/script/hooks/commit-msg
Executable file
@ -0,0 +1,24 @@
|
||||
#!/bin/bash
|
||||
|
||||
msg=$(cat $1)
|
||||
|
||||
OLD_GIT_DIR=$GIT_DIR
|
||||
|
||||
if [[ "${msg}" != *"[ci skip]"* ]]; then
|
||||
if [ "$(penchant gemfile-env)" != "remote" ]; then
|
||||
penchant gemfile remote
|
||||
fi
|
||||
|
||||
bundle exec rake
|
||||
R=$?
|
||||
if [ $R -ne 0 ]; then exit $R; fi
|
||||
fi
|
||||
|
||||
if [ "$(penchant gemfile-env)" != "remote deployment" ]; then
|
||||
unset GIT_DIR
|
||||
penchant gemfile remote --deployment
|
||||
GIT_DIR=$OLD_GIT_DIR
|
||||
git add Gemfile*
|
||||
fi
|
||||
|
||||
|
@ -1,19 +1,4 @@
|
||||
#!/bin/bash
|
||||
|
||||
OLD_GIT_DIR=$GIT_DIR
|
||||
|
||||
if [ "$(penchant gemfile-env)" != "remote" ]; then
|
||||
penchant gemfile remote
|
||||
fi
|
||||
|
||||
bundle exec rake
|
||||
R=$?
|
||||
if [ $R -ne 0 ]; then exit $R; fi
|
||||
|
||||
if [ "$(penchant gemfile-env)" != "remote deployment" ]; then
|
||||
unset GIT_DIR
|
||||
penchant gemfile remote --deployment
|
||||
GIT_DIR=$OLD_GIT_DIR
|
||||
git add Gemfile*
|
||||
fi
|
||||
# this has been moved to commit-msg
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user