Update on moving Bugzilla to git
Damien
damien.nozay at gmail.com
Sat Jan 11 00:01:19 UTC 2014
Hey Mark,
from https://github.com/markrcote/bugzilla-git-migration:
However, since git doesn't have the concept of commit properties, piping
> this data into git fast-importresults in errors. We can, however, translate
> the fast-export output by storing commit properties in the git commit
> messages. Even better, we can check if the bug number is already present in
> the commit message and only add the bug info if it isn't.
You could use git notes for the additional metadata / bzr commit properties.
http://git-scm.com/blog/2010/08/25/notes.html
e.g. ref/notes/reviews for the r/a flags.
and ref/notes/bugs for the bug links.
e.g. sample workflow:
1) get patch / commit from other remote
2) review it, use git-notes to add a note (r/a flags)
3) if there is a relevant bug, add a note.
If you think about it, if the patch you get from the user is okay, you don't
need to modify the message (!= SHA1) to add notes (same SHA1). this allows
consistent objects between your repo / somebody else's repo, etc.
$0.02
Damien.
On Fri, Jan 3, 2014 at 2:56 PM, Mark Côté <mcote at mozilla.com> wrote:
> Another update: I've finished the two scripts. The first is for the
> initial migration, which translates bzr's fast-export output into
> git-friendly fast-import input, specifically adding the "bug" commit
> property to the git commit message, if it exists and if the referenced
> bug is not already mentioned in the commit message. This is a C#
> script, which I know is a bit odd, but I found it on a blog post, and it
> was easier to make a few changes than rewrite it in Perl or Python or
> Bash or another language that makes more sense on *NIX platforms. It
> runs fine under mono on Linux.
>
> The second script keeps the Bazaar branches in check with the git
> branches. It's Perl, based off of the current bzr-to-cvs.pl script, as
> mentioned in my previous post.
>
> I've created a repo in GitHub with these scripts and a README explaining
> how we intend to do the migration:
> https://github.com/markrcote/bugzilla-git-migration. I invite anyone
> interested to take a look and even try it out; there are instructions on
> testing in the README.
>
> I've done conversions of Bugzilla trunk and 4.2 using the latest version
> of the migration script and pushed them to a GitHub repo as examples
> (the plan is still to have the official repos hosted on git.mozilla.org
> with one-way mirrors to GitHub): https://github.com/markrcote/bugzilla
>
> I'm not sure of the exact timing of the migration. I'm thinking
> February/March, when we can both get some feedback on these scripts (in
> case I've made any glaring errors) and schedule some IT time.
>
> Mark
>
>
> On 12/10/2013, 4:16 PM, Mark Côté wrote:
> > Just wanted to give a brief update on the plan to transition to git to
> > assure all that it is still progressing.
> >
> > I've fleshed out the wiki page[1], including a step-by-step plan. I've
> > got a one-time migration script working based on [2] that preserves the
> > bug ID commit metadata, although I need to tweak it slightly to only
> > annotate commits that don't reference the bug mentioned in the metadata
> > (the original script does this, but I need to change it to Bugzilla's
> > standard). An example of the resulting migration for bmo/4.2 is at [3].
> >
> > Finally, I have a git-to-bzr.pl script working based on the previous
> > migration script, bzr-to-cvs.pl[4]. I will be posting it for review
> > very soon.
> >
> > Mark
> >
> >
> > [1]: https://wiki.mozilla.org/Bugzilla:Migrating_to_git
> > [2]:
> http://www.fusonic.net/en/blog/2013/03/26/migrating-from-bazaar-to-git/
> > [3]: https://github.com/markrcote/bmo
> > [4]:
> http://bzr.mozilla.org/bzr-plugins/bzr-to-cvs/view/head:/bzr-to-cvs.pl
> >
>
> _______________________________________________
> dev-apps-bugzilla mailing list
> dev-apps-bugzilla at lists.mozilla.org
> https://lists.mozilla.org/listinfo/dev-apps-bugzilla
> -
> To view or change your list settings, click here:
> <http://bugzilla.org/cgi-bin/mj_wwwusr?user=$MSGRCPT>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.bugzilla.org/pipermail/developers/attachments/20140110/4d0973fd/attachment.html>
More information about the developers
mailing list