On 01/11/05, Chris Mason <mason@suse.com> wrote: > On Tue, Nov 01, 2005 at 10:08:04AM +0100, Petr Baudis wrote: > > Did anyone do any current detailed comparison between hg mq and StGIT? > > I don't think so, but I'll give it a rough try. I have not used stgit > extensively, so please correct any mistakes below. Most of the > differences center around the ways we store patches. Thanks for this comparison. It is correct. > mq is closer to quilt. The patches are stored as patches, and hg qpush > is very similar to importing a patch. This means metadata must be > stored at the top of the patch in some form the import code can > understand (it tries to be smart about this). The problem with this is allowing people to modify the patch directly (with vi). This would make it difficult to do a three-way merge without either losing the direct changes or simply failing to apply a modified patch to its old base (I thought about using patches as an optimisation but after some benchmarking found that "git-diff-tree | git-apply" is fast enough and most of the time when pushing is calculating the sha1 hash of the resulting index file). > hg qrefresh will update the patch file, so the patch is always up to > date wrt to the hg repo. Chuck, I think, has a patch to automatically export the patch when pushing or refreshing. With the latest StGIT snapshot, the tool reports if the patch was modified during push and can only be exported in this case (the way it detects this is by assuming that if git-apply is successful, the patch is unmodified since no fuzzy applying is accepted; the fall back to three-way merge just reports the patch as modified). > You can import/export patches with hg commands, or by copying patches > into/from the .hg/patches directory. This also means you can take a > quilt patch dir, copy it into .hg/patches and just start using mq. As I said, you might have problems with implementing a three-way merge. > I'm not sure if stgit has some form of annotate, but it's a nice way to > find out which patch changed a given loc in hg/mq. There is git-whatchanged which also reports the StGIT patches applied onto the stack. But there is no command similar to 'quilt patches' yet. -- Catalin - To unsubscribe from this list: send the line "unsubscribe git" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.htmlReceived on Wed Nov 02 04:29:56 2005
This archive was generated by hypermail 2.1.8 : 2005-11-02 04:30:00 EST