[postgis-devel] Current git-svn workflow

Paragon Corporation lr at pcorp.us
Sun Sep 22 09:22:45 PDT 2013


Oops I screwed up already and used it.  Can you a reinitialize until I get
up to speed on git and once you do that I'll just manually commit Kashif's
changes via SVN. 

I apologize for not asking first.  I realized only after the fact that I
might have done something wrong. 

I think we need to tell people to not send Git pull requests and to do
regular diffs until we are fully on Git.

Thanks,
Regina



-----Original Message-----
From: Sandro Santilli [mailto:sandro.santilli at gmail.com] On Behalf Of Sandro
Santilli
Sent: Sunday, September 22, 2013 5:20 AM
To: postgis-devel at lists.osgeo.org
Cc: Paragon Corporation; Paul Ramsey
Subject: Current git-svn workflow

So that you know, the git _mirror_ of the postgis codebase is currently an
output-only repository. There's a script on my hosted machine that runs
hourly and mirrors anything that happened in the SVN repo onto the git repo.

You can find the script at the end of the email (after the signature).

The consequence of this is that you cannot push non-svn derived commits in
the git repo without breaking the script (which will currently refuse to
push new things upstream due to loss of sync).
The script could be made to force-push, in which case you'd loose direct
pushes anyway.

So button-click pull merging is not supported. Please don't use it.

Now, we _might_ improve that by setting up some form of backward sync, but
is it worth it ? A core committer should still review the changes, and
should probably add acknoledgement (as SVN doesn't know about author !=
committer) and possibly squash-rebase the whole branch to make reviews of
others easier (I hate non-linear history full of noise). And maybe also add
reference to a ticket (recommended).

For now I think the simplest thing is to keep committing to SVN as an
"official push", until someone steps up to work on a smooth full migration
to git (requires adding git knowedge to osgeo trac:
http://trac.osgeo.org/osgeo/ticket/720)


--strk; 


The script :

cd /usr/src/postgis # this dir was previously git-svn initialized {  date
cd postgis  git svn fetch

 # Mirror all branches
 git branch -r | grep -v `git remote`  | grep -v tags |  grep -iv 2007 |
grep -v pgis | grep -v refractions |  sed 's/ *//' |
   while read; do
     cmd="git push origin ${REPLY}:refs/heads/svn-${REPLY}"
     echo $cmd
     $cmd
   done

 # Mirror all tags
 git branch -r  | grep  tags | sed 's/ *tags\///' |  while read; do git tag
"${REPLY}" tags/$REPLY; done

 git push origin --tags

}





More information about the postgis-devel mailing list