Converting svn to git, how to get the branches not to be just remote in the svn repo? -
I am quite new to git and I am trying to transfer the svn repository to GIT. I have followed the guidelines below so now I have a GIT repo on my server.
So, if I "Master" the answer to GIT "GIT" branch and if I get a list of all the branches in the SVN repository "GIT Branch-R".
One of my previous SVN checkin's branches, but when I did "GIT SVN Clone", then my command in that branch (not yet merged with the trunk) was my Master's Branch (GIT) What are I missing here?
In addition, if I "cluster GIT" on my development machine, then I get the file ok. But if I do "GIT branch-R" then I can see only the master branch and can not see remote branches. "
Since we are all getting rid of SVN-repo, I have SVN branches in all GIT-repo so that they can be accessed with developer clients.
Again, I am a total GIT novice So, if something fundamental I '
update
After doing some RTFM (Man GIT-SVN), I have a branch in the master branch First problem solved with content
reset - lose D Remote / Trunk
Now the trunk and master branch are the same, now, to find out how to get the branches, the development client.
Update 2 < / Strong>
I had to work on adding url and url above the URL which Scott had indicated. So, from the beginning.
I created a blank store on the server for the first time, Rver is included in / usr / local / git-repos in:
server> CD / USR / local / GIT -Repo Server & gt; Mkdir my_project.git server & gt; CD my_project.git server & gt; Git init
Then I cloned svn-repository on my Dev-machine (Attention Give, "branches" on our SVN server are called "branches" witout the 's'):
dev> Git svn clone http: //
Then to get some clear-up tags and branches:
dev> Cp-rf .git / refs / remotes / tags / * .git / refs / tags / dev & gt; RM-RF .Git / RFS / Remote / Tag Dev> CP-RF .Git / RFS / Remote / * .git / refs / heads / dev & gt; Now add your server as a remote repository: dev> Finally, push all the branches and tag them to the server: / P> Dev> Drink, now you have it, now I can get rid of that SVN-repo. Update 3 strong>
Checkout for an easy way to do this ...
one is enough
There is a short answer to running:
$ cp -rf .git / refs / remotes / * .git / refs / heads / $ rm -rf .git / refs / remotes
Hope that's helpful is.
Comments
Post a Comment