5

I am trying to checkout a specific revsion of my svn codebase. Normally, to checkout, I just type
git svn clone svn+ssh://path_to_codebase. I need to checkout an older version of the codebase. How do I do that?

2 Answers 2

11

I used the following and I obtained an older revision.

git checkout `git svn find-rev revision_number`   

Does anyone have any comments about this?

Sign up to request clarification or add additional context in comments.

Comments

7

You can git svn clone it as usual and then use the usual tools -- git checkout can give you access in a "floating" way or create a new git branch at your desired point.

You can also use git svn init (note it behaves slightly differently than git init) and then git svn fetch -r XXX to fetch a specific revision. This is much faster if the repository is large, but a future git svn fetch will fetch the rest of the revs (but never any earlier revs).

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.