Why does this series of git-svn commands result in a detached HEAD?

I do this:

$ git svn clone http://monsterdebugger.googlecode.com/svn/ -s --prefix=svn/ monsterdebugger
$ cd monsterdebugger
$ git branch -a
* master
$ git co remotes/svn/trunk
Note: checking out 'remotes/svn/trunk'.

You are in 'detached HEAD' state. <And so on...>

I guess I’m not fully understanding what’s going on under the hood here. Shouldn’t remotes/svn/trunk be a tracking branch against the svn repo? Why did I end up with a detached head?

  • Syncing dev/production with git, with a file-based CMS
  • How do I run a git repository locally with multiple users?
  • kdiff3 selecting the file from remote completely
  • Git push pushes nothing
  • Git Mess! Commits in the wrong branch
  • Git diff between given two tags
  • I cloned a git repository. How do I pull from it into a working directory?
  • GIT Removing FETCH refs from remote tracking
  • bash read git log and print it to .xml format (RSS)
  • Git Tools show different history
  • Git thinks I've renamed a file rather than deleting one and creating another
  • merge two git repositories - consistent history
  • One Solution collect form web for “Why does this series of git-svn commands result in a detached HEAD?”

    It’s because it’s a remote branch. You need to create a local branch for it, with something like:

    git checkout -b my-trunk remotes/svn/trunk
    Git Baby is a git and github fan, let's start git clone.