git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Newbie question about setting up git repository from svn (git svn)

From
Hillel (Sabba) Markowitz <sabbahillel@gmail.com>
Date
Mar 4, 2011, 15:57 UTC
Message-ID
<AANLkTi=UG4oq4QHhKoDOi9+4bhF1TDy4Z26ORj9Bdcwc@mail.gmail.com>

Please respond directly to sabbahillel@gmail.com as I do not have time to follow this mailing list.

I am attempting to set up a git repository based on an svn repository. The idea would be that the members of the project would be able to use git exclusively with the central git repository acting as the coordinator. This git server would be the only one capable of issuing the git svn dcommit and git svn rebase and the members of the project would not have to worry about it. Eventually, the subversion repository would be transferred to git.

I created a separate Ubuntu VM in order to set up the git repository. I used "git svn clone -s" to set up MyProject.git on "gitserver"

The command "git branch -a" shows
* master
  remotes/branch1
  remotes/branch2
  remotes/trunk
I then went to my main VM and used ssh to clone the repository
git clone gitserver:/opt/git/MyProject
cd MyProject
git branch -a
* master
  remotes/origin/HEAD -> origin/master
  remotes/origin/master

How do I check out the trunk or appropriate branches from the remote? I am probably misreading the documentation. Would it be

git checkout -b branch1

does the master on the remote (and here) actually point to the trunk by default? should I checkout the branches on "gitserver"?

I also do not see how I can get the list of branches from the remote location.without having to do an ssh into the gitserver, cd to the repository directory, and use a 'branch -a' there. Is there a way to ask for this information? I have not yet been successful in setting up gitosis yet because this is on an internal company intranet and I do not have a valid machine name for my accounts as everything is being done on VMs. Thus, my public key ends with "sabbahillel@desktop-ubuntu" rather than an actual machine name or address.

Would you have a pointer to a HOW-TO that discusses this.
Thanks for any help that you can give me.
--
       Sabba     -          סבא הלל        -     Hillel
Hillel (Sabba) Markowitz | Said the fox to the fish, "Join me ashore"
 SabbaHillel@gmail.com | The fish are the Jews, Torah is our water
http://sabbahillel.blogspot.com
Next: Neal Kreitzinger
Message 1 of 4 in “Newbie question about setting up git repository from svn (git svn)”
  1. Hillel (Sabba) MarkowitzMar 4, 2011
  2. Neal KreitzingerMar 7, 2011
  3. Neal KreitzingerMar 7, 2011
  4. Hillel (Sabba) MarkowitzMar 7, 2011

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.