Hi Everyone, What can I say, I was too optimistic about how easy it would be to convert GCC's svn repo to git one branch at a time. After 2 more weeks and several re-writes of the scripts I now know more about GCC's svn history than I would ever wanted.
The prize for most complicated branch history goes to /branches/ibm/* . It has merges, it has re-creation branches from /trunk and even an accidental deletion of all of IBM's branches. The version of scripts I'm testing right now seems to deal with all of that. Also, to avoid controversy -- I'm working on these scripts to satisfy my own curiosity, and to give GCC community another option to choose from for the final migration. If by end of Summer 2019 we have 2-3 git repos to choose from, then we are likely to push GCC [kicking and screaming] into 2010's by the end of this decade. -- Maxim Kuvyrkov www.linaro.org > On May 14, 2019, at 7:11 PM, Maxim Kuvyrkov <maxim.kuvyr...@linaro.org> wrote: > > This patch adds scripts to contrib/ to migrate full history of GCC's > subversion repository to git. My hope is that these scripts will finally > allow GCC project to migrate to Git. > > The result of the conversion is at > https://github.com/maxim-kuvyrkov/gcc/branches/all . Branches with "@rev" > suffixes represent branch points. The conversion is still running, so not > all branches may appear right away. > > The scripts are not specific to GCC repo and are usable for other projects. > In particular, they should be able to convert downstream GCC svn repos. > > The scripts convert svn history branch by branch. They rely on git-svn on > convert individual branches. Git-svn is a good tool for converting > individual branches. It is, however, either very slow at converting the > entire GCC repo, or goes into infinite loop. > > There are 3 scripts: > > - svn-git-repo.sh: top level script to convert entire repo or a part of it > (e.g., branches/), > - svn-list-branches.sh: helper script to output branches and their parents in > bottom-up order, > - svn-git-branch.sh: helper script to convert a single branch. > > Whenever possible, svn-git-branch.sh uses existing git branches as caches. > > What are your questions and comments? > > The attached is cleaned up version, which hasn't been fully tested yet; typos > and other silly mistakes are likely. OK to commit after testing? > > -- > Maxim Kuvyrkov > www.linaro.org > > > <0001-Contrib-SVN-Git-conversion-scripts.patch>