Skip to content

Instantly share code, notes, and snippets.

@dokipen
Created April 20, 2010 18:49
Show Gist options
  • Save dokipen/372883 to your computer and use it in GitHub Desktop.
Save dokipen/372883 to your computer and use it in GitHub Desktop.
git-svn fetch madness
Sometimes, when adding a branch like so:
`fetch = path/to/branch:refs/remotes/git-svn/mynewbranch`
the path to the branch is mispelt.
You then go ahead and do a `$ git svn fetch` and git finds nothing. You realize what an incredible dolt you are and fix the path,
`fetch = realpath/to/branch:refs/remotes/git-svn/mynewbranch`
then run `git svn fetch` again..... And it does nothing. WTF! The problem is, git-svn decided to store some metadata about what revisions were checked so it doesn't have to check them again based on the remote tracking branch name. It's not going to check them again as long as that data exists. The solution is simple:
`$ rm .git/svn/git-svn/mynewbranch -Rf && git svn fetch`
This was fun, let's do it again soon.
@dokipen
Copy link
Author

dokipen commented Mar 29, 2012

March the Twenty and Ninth of the Year Two-Thousand and Twelve

To My Dearest Friend POLM,

You are too kind. When I first wrote the git-svn gist, I wasn't sure if my efforts would be rewarded. In other words, was it worth it? Of course, helping your fellow human has it's own rewards, but would anyone ever be helped by it?

Now I can say, with confidence, that my efforts have been rewarded one-thousand fold. I am swimming in metaphysical profits! I'm pretty much all set on blessings forever, and so is my family. So I thank you kindly.

It is only fair that I bless you and yours in turn. So I beg of the Grand and Illustrious Creator to bless you and your offspring, from whatever Creator you happen to subscribe to, for now and for eternity. Whether it be chance, fate, maths, God or The Gods, bless you! For you are a wise and learned man!

Your Humble Git Helper,

Robert Christopher Corsaro

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment