]> git.wh0rd.org Git - home.git/commitdiff
skip repos that are in the middle of a rebase
authorMike Frysinger <vapier@gentoo.org>
Tue, 23 Oct 2012 19:02:04 +0000 (15:02 -0400)
committerMike Frysinger <vapier@gentoo.org>
Tue, 23 Oct 2012 19:02:04 +0000 (15:02 -0400)
.bin/r

diff --git a/.bin/r b/.bin/r
index e4c83991a14f9181cc5d9fe00675ae05290889ef..5d497555e18d8dac9b2a2c3d29437fdfdfce6198 100755 (executable)
--- a/.bin/r
+++ b/.bin/r
@@ -68,7 +68,7 @@ rebase)
                                proj=${line[2]}
                                cd "${root}/${dir}"
                                (
-                               out=$(r rb all . 2>&1)
+                               out=$(env _proj=${proj} r rb all . 2>&1)
                                [[ -n ${out} ]] && echo "${out}"
                                _mj_child
                                ) &
@@ -94,6 +94,11 @@ rebase)
 
                eval $(bash-colors --env)
                #echo "${GOOD}### ${PWD}${NORMAL}"
+               # Skip if rebase is in progress.
+               if [[ -e .git/rebase-merge/interactive ]] ; then
+                       echo "# ${_proj}: skipping due to active rebase"
+                       exit 1
+               fi
                for b in ${branches} ; do
                        #echo " ${HILITE}### $b${NORMAL}"
                        g co -q $b || exit 1