Skip to content

Commit 02da705

Browse files
committed
Commited a broken version in my haste last night :(
* Remove debug code * Fix broken migration check * Fix reference to old '.sh' script name
1 parent ca7dd33 commit 02da705

File tree

2 files changed

+2
-3
lines changed

2 files changed

+2
-3
lines changed

bin/git_rails

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ if [ ! -z "$migrations_removed" ]; then
3838
git checkout $new_ref -- db/schema.rb
3939
fi
4040

41-
if [ ! -z "$old_ref" ]; then
41+
if [ ! -z "$migrations_added" ]; then
4242
echo "New migrations have been added running migrations"
4343
bundle exec rake db:migrate db:test:prepare
4444
git checkout $new_ref -- db/schema.rb

hooks/post-checkout

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,5 @@ old_ref=$1
44
new_ref=$2
55

66
if [ $checking_out_branch -eq 1 ] && b=$(git symbolic-ref --short -q HEAD); then
7-
pwd
8-
git_rails.sh $old_ref $new_ref
7+
git_rails $old_ref $new_ref
98
fi

0 commit comments

Comments
 (0)