I have a git repository fully tracking a remote SVN repo. Now I need to add a new branch that will be tracking a directory in a completely different SVN repo.
Is that possible?
No interaction between them. Just ignore the . git folder for SVN and the . svn folder for Git and you should be fine.
# Clone a repo with standard SVN directory layout (like git clone): git svn clone http://svn.example.com/project --stdlayout --prefix svn/ # Or, if the repo uses a non-standard directory layout: git svn clone http://svn.example.com/project -T tr -b branch -t tag --prefix svn/ # View all branches and tags you have ...
SVN does not have the concept of local repository/remote repository, accordingly commit is directly reflected in the remote.
It is. git svn init
only edits the default svn remote, you'll have to edit the config file.
Look in .git/config
, copy and alter the existing svn-remote section, and run git svn fetch
. For example:
[svn-remote "svn2"]
url = http://bzzz.googlecode.com/svn
fetch = trunk:refs/remotes/svn2/trunk
branches = branches/*:refs/remotes/svn2/*
tags = tags/*:refs/remotes/svn2/tags/*
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With