Questions tagged [svn2git]

There are multiple utilities called svn2git that do the same task, transforming an SVN repository into one or multiple Git repositories. This tag can be used for any of them.

The KDE svn2git utility is probably the most sophisticated, most flexible and fastest tool amongst the ones called svn2git.

It is fed with a set of rules that define how the SVN content should be transformed into one or even multiple Git repositories or combine different SVN repositories in one SVN location into one Git repository.

It is often used in conjunction with svneverever to easily analyze the history of a repository and its committers to aid in setting up a rules file if the history of the repository was not straightforward.


Another svn2git utility available is the one of nirvdrum which uses git-svn for importing the SVN repository and then does some post-processing which is in total extremely time consuming and produces sometimes a bit of a borked history or missies the history from some point on.

126 questions
26
votes
5 answers

Converting a local svn repo dump to git

I searched related questions but I couldn't find anything matching my specific situation: I have some old repository archives from an SVN server that was taken down years ago. They're tarballs of the original repository structure on the server. What…
R.. GitHub STOP HELPING ICE
  • 195,354
  • 31
  • 331
  • 669
11
votes
5 answers

Maven Release-plugin "tag already exists" for nonexistant tag

My setup: git-repository on an Atlassian Stash-server and Atlassian Bamboo. I'm using Maven 3.1.1 with the release-plugin 2.3.2. The plan in Bamboo looks like this: Check out from git-repository perform a clean install perform release:prepare and…
Vince
  • 1,479
  • 2
  • 16
  • 39
11
votes
4 answers

svn2git: Cannot setup tracking information

I am trying to migrate a SVN project to git with thel help of svn2git. When executing the command it exits with the following error: Running command: git branch --track "0.0.9" "remotes/svn/0.0.9" fatal: Cannot setup tracking information; starting…
pderaaij
  • 1,327
  • 12
  • 32
9
votes
3 answers

svn2git - command failed - error: pathspec 'master' did not match any file(s) known to git

We are trying to migrate from svn to git using svn2git utility (https://github.com/nirvdrum/svn2git). The utility seems to fail every time with below error. If anyone has seen the same error or have any better alternatives, please…
Jaydip Rakholiya
  • 733
  • 10
  • 19
9
votes
1 answer

Import part of a SVN repository into an existing Git repo

I have an existing SVN repo and I would like to import a part of it, with history into an existing Git repo. Could anyone give me a high-level overview of the commands needed to do this? Summary: I want to move some subdirectories in an existing…
Andrew Mao
  • 31,800
  • 17
  • 126
  • 212
7
votes
1 answer

Exclude deleted svn branches/tags on migration to git (git-svn)

I'm currently migrating a huge repository with a long history from SVN to git. The svn repository has many branches and tags. I've cleaned up a lot of them from the SVN repo, but when I use the git svn clone command, it clone all the deleted…
hfm
  • 506
  • 1
  • 6
  • 21
7
votes
3 answers

svn to git conversion: Correct remote ref must start with 'refs/' error

(I'm posting this question with the intention of answering it myself as I could not find the answer elsewhere. Hopefully it will help others who run into the same issue and it will help me next time I'm trying to do it.) The Challenge I want to…
mkaatman
  • 4,760
  • 1
  • 28
  • 49
6
votes
1 answer

Why does `git-svn` hang at `Found possible branch point:`

Since a few days, my git-svn hangs at Found possible branch point: .../trunk => .../branches/foo, 8809 when I do git svn fetch. The clone acutally is at revision 163671 already. My box had a freeze lately, so it might be that something got stuck…
Vampire
  • 31,050
  • 2
  • 58
  • 88
6
votes
1 answer

What are the pros and cons of the --svn-branches parameter to svn2git

I'm using svn2git (the good one) to transform some SVN repositories to Git repositories. It has a commandline parameter --svn-branches which is documented with Use the contents of SVN when creating branches, Note: SVN tags are branches as…
Vampire
  • 31,050
  • 2
  • 58
  • 88
5
votes
3 answers

How do I migrate a flat svn repo to git repo

I have a flat svn repository which looks like: my_repo/ ├── file1.c ├── file2.c ├── file3.c └── README This repo has no branches, or tags and all I am trying to do is convert it to a git repository and maintain the commit history. I have tried: git…
user3277112
  • 157
  • 2
  • 5
4
votes
1 answer

How do I checkout an entire SVN repository with all the history, tags and versions

I have a very large SVN repository (nearly 6000 revisions) which I need to migrate to Git. The repository is hosted on an internal server. I want to migrate all the history, tags and versions to Git and have branches etc in Git format. So far, I…
Idris.AH
  • 338
  • 5
  • 17
4
votes
2 answers

Is there any way to speed up git svn?

I am trying to convert an SVN repository to Bit Bucket, with 18 years of history, over 6000 branches and over half a million commits. Git svn went through the first 50k commits in about 6 hours and has spent 3 days converting the next 40k. It has…
eeijlar
  • 1,010
  • 2
  • 11
  • 40
4
votes
1 answer

Using git svn on a repo created with svn2git

We are migrating an old SVN repository to Git. This worked pretty well with svn2git. Now we want to exclusively work on git but need to mirror any new git commits to the old SVN repository. This is necessary because some production systems still are…
Michael Härtl
  • 8,049
  • 5
  • 31
  • 56
3
votes
1 answer

How to migrate svn repository to git with svn2git?

I want to migrate a repository from svn to git. I'm using svn2git from this repository: https://github.com/svn-all-fast-export/svn2git When I do : svn2git/svn-all-fast-export --rules ruleset/module svn/module I get this error: svn: E000002: : Can't…
Beto
  • 437
  • 3
  • 9
3
votes
1 answer

How to use svn2git on repository

I'm using svn2git to test the migration of an svn repo to a git. Now my svn is build like thise myproj contains repo1 / repo2 (obsolete)/ old/ Every repo contains its own branches, tags etc. I only need everything which is in repo1. When I start…
DenCowboy
  • 10,114
  • 24
  • 80
  • 168
1
2 3
8 9