[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

git-migration: Changes to 'master'



 clone |   26 ++++++++++++++++++++++----
 1 files changed, 22 insertions(+), 4 deletions(-)

New commits:
commit 0726222645eb8e6e4f25056e8f7244b4566825e3
Author: Thierry Reding <thierry@gilfi.de>
Date:   Wed Jan 3 17:50:06 2007 +0100

    Implement the proposed XSF git archive policy.

diff --git a/clone b/clone
index 5df6b30..da15d46 100755
--- a/clone
+++ b/clone
@@ -13,17 +13,35 @@ (
 		debian=$(echo $line | cut -d' ' -f1)
 		upstream=$(echo $line | cut -d' ' -f2)
 
+		echo "Setting up $debian for cloning..."
 		if [ -d "$debian.git/.git/remotes" ]; then
 			# create remote `origin' branch for the alioth repositories
 			cat > "$debian.git/.git/remotes/origin" << EOF
 URL: ssh://git.debian.org/git/pkg-xorg/$debian.git
-Pull: refs/heads/master:refs/heads/master-origin
+Push: refs/heads/master:refs/heads/debian-unstable
+Push: refs/heads/upstream-master:refs/heads/upstream-master
 EOF
 
+			(
+				cd "$debian.git" &&
+				git-branch | sed -e 's/^\*\? \+//' |
+				(
+					read b
+					while [ "x$b" != "x" ]; do
+						if [ "x$b" != "xmaster" ]; then
+							echo "Pull: refs/heads/$b:refs/heads/svn-$b" \
+								>> .git/remotes/origin
+						fi
+
+						read b
+					done
+				)
+			)
+
 			# create remote `upstream' branch
 			cat > "$debian.git/.git/remotes/upstream" << EOF
 URL: git://anongit.freedesktop.org/git/$upstream
-Pull: refs/heads/master:refs/heads/master-upstream
+Pull: refs/heads/master:refs/heads/upstream-master
 EOF
 
 			# fetch latest master head from upstream branch
@@ -31,8 +49,8 @@ EOF
 		fi
 
 		# cleanup .git directory, removing leftover SVN migration files
-		rm "$debian.git/.git/svn2git"
-		rm "$debian.git/.git/svn-authors"
+		rm -f "$debian.git/.git/svn2git"
+		rm -f "$debian.git/.git/svn-authors"
 
 		read line
 	done



Reply to: