]> git.xonotic.org Git - xonotic/xonotic.git/blobdiff - all
Merge branch 'master' of ssh://xonotic@git.xonotic.org/xonotic
[xonotic/xonotic.git] / all
diff --git a/all b/all
index 9a0a6d0ca0041aafda51f3dc693d65dd34a57737..6166c77cf1d9461bce81868b9eebdf94b89f252b 100755 (executable)
--- a/all
+++ b/all
@@ -119,6 +119,16 @@ repos_urls="
        netradiant
 "
 
+repos_urls=`
+       for X in $repos_urls; do 
+               d="${X%%@*}"
+               p="${d%dir}"
+               if [ x"$p" = x"$d" ] || [ -d "$d" ] || ! [ -f "$p" ]; then
+                       echo "$X"
+               fi
+       done
+`
+
 repos=`for X in $repos_urls; do echo "${X%%@*}"; done`
 
 if [ "$#" = 0 ]; then
@@ -166,7 +176,8 @@ case "$cmd" in
                                if git config branch.$r.remote >/dev/null 2>&1; then
                                        if ! verbose git pull; then
                                                check_mergeconflict "$d"
-                                               exit 1 # FATAL
+                                               echo "Pulling failed. Press ENTER to continue, or Ctrl-C to abort."
+                                               read -r DUMMY
                                        fi
                                fi
 
@@ -232,13 +243,17 @@ case "$cmd" in
                                dv=`visible_repo_name "$d"`
                                enter "$d0/$d" verbose
                                a=
-                               while [ x"$a" != x"y" -a x"$a" != x"n" ]; do
-                                       echo "Branch in $dv?"
-                                       read -r a
-                               done
-                               if [ x"$a" = x"y" ]; then
-                                       verbose git push "$remote" "$srcbranch":"$branch"
-                                       verbose git checkout --track -b "$branch" "$remote/$branch"
+                               if git rev-parse "refs/heads/$branch" >/dev/null 2>&1; then
+                                       echo "Already having this branch in $dv."
+                               else
+                                       while [ x"$a" != x"y" -a x"$a" != x"n" ]; do
+                                               echo "Branch in $dv?"
+                                               read -r a
+                                       done
+                                       if [ x"$a" = x"y" ]; then
+                                               verbose git push "$remote" "$srcbranch":"$branch"
+                                               verbose git checkout --track -b "$branch" "$remote/$branch"
+                                       fi
                                fi
                                cd "$d0"
                        done