[Kde-scm-interest] Re: converting QMake plugin (was: importing subproject history)

Nicolas Alvarez nicolas.alvarez at gmail.com
Mon Nov 29 15:34:50 CET 2010

Torgny Nyblom wrote:
> On Saturday 27 November 2010 22.14.08 Nicolas Alvarez wrote:
>> I'm trying to convert the KDevelop QMake plugin:
>> http://websvn.kde.org/trunk/playground/devtools/kdevelop4-extra-
>> plugins/qmake/?view=log
>> (That's the current path, it moved around a lot in previous revisions.)
>> 'qmakebuilder' used to be in a separate directory, usually a sibling of
>> 'qmake' (other times a 'cousin' directory). Later, it was moved into
>> /qmake/qmakebuilder.
>> I want to get the full history of both.
>> Oswald Buddenhagen wrote:
>> > - convert the history of the subproject separately up to the point
>> > where it moves into the main project
>> > 
>> > - make an interactive rebase of the main project and make it stop at
>> > the commit where the subproject moves into it (mark the commit for
>> > edit, obviously)
>> > 
>> > - note that sha1, then throw the commit away with reset --hard HEAD~1
>> > - git remote add -f subproject1 /path/to/subproject1
>> > - git merge -s ours --no-commit subproject1/master
>> > - git cherry-pick <remembered sha1>
>> > - git rebase --continue
>> The problem with this solution is that there are many SVN commits that
>> touch both qmake and qmakebuilder, and I'd like to keep those as atomic
>> git commits too.
>> I thought of putting 'qmake' and 'qmakebuilder' as directories in the git
>> repo, corresponding to the two projects in SVN. Then, in r972147, all
>> files under qmake would move to the root of the git repo, and files in
>> qmakebuilder would stay there. But I have no idea how to do this in
>> svn2git, or if it's possible at all.
>> Ideas?
> match /trunk/qmakebuilder/
> repository kdevelop-qmake
> branch master
> prefix qmakebuilder/
> end match
> match /trunk/qmake/
> repository kdevelop-qmake
> branch master
> prefix qmake/
> end match
> ought to do it.

So far, that seems to have worked great; thanks!

It'd be better if, after the move, I'd get the qmake files in the root 
instead of a qmake subdirectory. But that's possible and probably easy with 


More information about the Kde-scm-interest mailing list