I’ve cloned an SVN repository into git using git-svn, but I’m having trouble rebasing and I thought to work around it by using svn to generate a patch between the old SVN revision I’d used to clone my git repo in the first place and the current version. That way I could just apply the patch and call it rebased.
Any idea how I can find the SVN revision number my current git-svn clone is based on?
If you do
git logyou should be able to see a history of all commits in your repository. The first of these will correspond to the SVN revision that your git repository was cloned from.So, you might see something like this:
In this instance, you can see that I have cloned from revision 51174 of the remote SVN repo (fake paths and names used here)
You can simplify the output from
git logby using the--skip=<number>option (e.g.git log --skip=100, though this requires you to have some idea of the number of commits since you initially cloned the repository.