![]() This will essentially extract your changes as a series of patches and reapply them to the git-svn (i.e. However, if you have local changes then you probably want to use rebase as it more closely matches the behavior of svn up. If you have no local changes, you can do a fast-forward merge of upstream commits into your current development branch:: git merge git-svn To fetch new commits, run:: git fetch git-svn The most efficient method to update your local respository is to use the Git protocol before using git svn. Note that this can be slow if your repository is far behind the Subversion repository. It will fetch new versions from the Subversion repository and then rebase your local changes on top of them:: git svn fetch Using the git svn fetch command closely matches the behavior of the svn update command. This should complete quickly because nearly all the data is already local and the git-svn command will merely go through the logs and extract the Subversion revision numbers. Use git-svn to get up to the minute changes from the SVN server:: The local branch master and the remote branch git-svn now contain identical trees. Merge the changes from the git-svn branch into our development branch (normally you would first rebase your changes in master on top of git-svn but right now we don't have any):: Our main development branch is called 'master', athough we can create as many others as we like. We don't do our development on the git-svn branch since that follows the head of the public Subversion repository. To fetch that data into the local git-svn branch:: Note that you can use the git clone command to efficiently make local copies of the repository. ![]() The following command populates the local repository (this will download approximately 90 MB of data from ). Git config refs/heads/master:refs/remotes/git-svn Git remote add git-svn git:///python/trunk This is more efficient than using the Subversion protocol, especially if you are far behind the head:: Git svn init Git where the data can be fetched using the Git protocol. Tell git-svn where the Subversion repository is located (so you can use git-svn to push and pull changes to the SVN server). The following commands will initialize an empty repository:: Changes since that time can be pulled using git-svn.Įnsure that you have a recent Git (at least version 1.5.1). To allow that, there are Git repositories on that are updated every hour. You could use git-svn to create a local repository (please don't do that) but it's much faster to use the native git protocol. Git's pack format is efficient but the entire VC history of Python still consumes a lot of space (currently around 90 MB). * Operations like git diff and git log are much faster than the Subversion equivalents. * Git has some nice tools for dealing with local branches (rebasing them, for example). * The entire history is available locally so you easily work without network access. This document describes how to checkout the source as a Git repository. Python's source code currently maintained under the Subversion revision control system. They are necessarily complex because they try to be efficient in network bandwidth while still working with the existing Subversion infrastructure. When that happens, the Git repositories will likely stop being updated.Īlso note that these instructions should not be considered a good introduction to typical Git usage. Note that the Python source is eventually going to be moved from Subversion of Mercurial. This page is currently outdated.Ĭhecking out the Python Source Code with Git ![]() Python is now hosted in a Mercurial repository.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |