From 0d4e78c39f92c9974b54e53a9b160bcaa4877132 Mon Sep 17 00:00:00 2001 From: Chris Koeritz Date: Tue, 22 May 2018 11:20:54 -0400 Subject: [PATCH] tests careful update before commit suspecting this caused problems when upstream had changes, but we'll see; this makes the diagnostic output make more sense, plus it just makes more sense to do it in this order in general (like, why would i want to commit before i am sure there are no merge problems coming from upstream?). --- scripts/rev_control/version_control.sh | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) diff --git a/scripts/rev_control/version_control.sh b/scripts/rev_control/version_control.sh index 4e53a513..e0102f61 100644 --- a/scripts/rev_control/version_control.sh +++ b/scripts/rev_control/version_control.sh @@ -92,26 +92,34 @@ function do_revctrl_checkin() # least to call do_revctrl_simple_update, but is there a reason not to call the careful git update instead? #AHA, below we do call a careful git update, which is at least partially redundant with calling do_revctrl_simple_update here. # how about pushing the do_revctrl_simple_update down into the two cases that use it and just not calling it for the git case? - do_revctrl_simple_update "$directory" - exit_on_error "updating repository; this issue should be fixed before check-in." +#hmmm: trying the better seeming approach below now. pushd "$directory" &>/dev/null if [ -f ".no-checkin" ]; then echo "skipping check-in due to presence of .no-checkin sentinel file." elif [ -d "CVS" ]; then if test_writeable "CVS"; then + do_revctrl_simple_update "$directory" + exit_on_error "updating repository; this issue should be fixed before check-in." $blatt cvs ci . exit_on_error "cvs checkin" fi elif [ -d ".svn" ]; then if test_writeable ".svn"; then + do_revctrl_simple_update "$directory" + exit_on_error "updating repository; this issue should be fixed before check-in." $blatt svn ci . exit_on_error "svn checkin" fi elif [ -d ".git" ]; then if test_writeable ".git"; then + +#hmmm: trying this in front; i have a bad feeling we used to do it like this and there were problems from not committing first! +# a new set of steps we have to take to make sure the branch integrity is good. +do_revctrl_careful_update "$(\pwd)" + $blatt # put all changed and new files in the commit. not to everyone's liking. @@ -140,7 +148,7 @@ function do_revctrl_checkin() fi # a new set of steps we have to take to make sure the branch integrity is good. - do_revctrl_careful_update "$(\pwd)" +#hold do_revctrl_careful_update "$(\pwd)" # we continue on to the push, even if there were no changes this time, because # there could already be committed changes that haven't been pushed yet. -- 2.34.1