git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: hgmq vs. StGIT

From
CMChris Mason <mason@suse.com>
Date
Nov 1, 2005, 14:11 UTC
Message-ID
<20051101141149.GA26847@watt.suse.com>
In-Reply-To
<20051101090804.GA11618@pasky.or.cz>
On Tue, Nov 01, 2005 at 10:08:04AM +0100, Petr Baudis wrote:
Show 15 quoted lines
> Dear diary, on Tue, Nov 01, 2005 at 01:25:54AM CET, I got a letter
> where Theodore Ts'o <tytso@mit.edu> told me that...
> > For an example of how to make it a first-class operation, it might be
> > worthwhile to look at Chris Mason's "Mercurial Queues" extention to
> > Mercurial:
> > 
> > 	http://www.selenic.com/mercurial/wiki/index.cgi/MqExtension
> > 
> > I've used it once or twice, and hg mq is definitely very nice and
> > convenient, and it makes commits a first-class operation.  On the
> > other hand, I've found that the combination of quilt and
> > Mercurial/BK/git works just fine, even for my own internal development
> > of (for example) the e2fsprogs tree.
> 
> 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.

Both tools make patches into commits during push. This allows the various history commands to see the currently applied patches.

Both tools allow you to make changes to files without running some form of quilt add first.

StGIT has the ability to rebase patches via three-way merge. This is still on my todo list for mq.

StGIT patch storage is very different from quilt and mq. StGIT keeps git commit/tree objects around for patches that have been applied. It then stores a directory with metadata about the patch (author/description etc) and the ids of the git commit objects.

In StGIT, importing new patches seems to require stg import, and exporting patches requires stg export (or a similar git command). But once the patches are stored in stgit, push/pop will be very fast.

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).

hg qrefresh will update the patch file, so the patch is always up to date wrt to the hg repo.

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.

mq has some support for putting the patches directory under revision control (as a separate repository).

Most of the other differences come from differences between hg and git. 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.

-chris
Previous: Catalin MarinasNext: Linus Torvalds
Message 53 of 61 in “git versus CVS (versus bk)”
  1. waltOct 31, 2005
  2. Martin LanghoffOct 31, 2005
  3. H. Peter AnvinOct 31, 2005
  4. Linus TorvaldsOct 31, 2005
  5. Johannes SchindelinOct 31, 2005
  6. Linus TorvaldsOct 31, 2005
  7. wa1ter@myrealbox.comOct 31, 2005
  8. Randal L. SchwartzOct 31, 2005
  9. waltOct 31, 2005
  10. Daniel BarkalowNov 1, 2005
  11. Linus TorvaldsNov 1, 2005
  12. Joel BeckerOct 31, 2005
  13. Martin LanghoffOct 31, 2005
  14. Joel BeckerOct 31, 2005
  15. Petr BaudisNov 1, 2005
  16. Joel BeckerNov 1, 2005
  17. Petr BaudisNov 1, 2005
  18. Petr BaudisNov 7, 2005
  19. Josef WeidendorferNov 8, 2005
  20. Petr BaudisNov 8, 2005
  21. Randal L. SchwartzNov 1, 2005
  22. Linus TorvaldsNov 1, 2005
  23. Randal L. SchwartzNov 1, 2005
  24. Linus TorvaldsNov 1, 2005
  25. Junio C HamanoNov 1, 2005
  26. Junio C HamanoOct 31, 2005
  27. Joel BeckerOct 31, 2005
  28. Linus TorvaldsOct 31, 2005
  29. Junio C HamanoOct 31, 2005
  30. Joel BeckerOct 31, 2005
  31. Junio C HamanoNov 1, 2005
  32. Joel BeckerNov 1, 2005
  33. Martin LanghoffNov 1, 2005
  34. Joel BeckerNov 1, 2005
  35. Linus TorvaldsNov 1, 2005
  36. Petr BaudisNov 1, 2005
  37. Catalin MarinasNov 1, 2005
  38. Theodore Ts'oNov 1, 2005
  39. hgmq vs. StGITPetr Baudis, Nov 1, 2005
  40. Catalin MarinasNov 1, 2005
  41. Petr BaudisNov 1, 2005
  42. Catalin MarinasNov 1, 2005
  43. Chuck LeverNov 1, 2005
  44. Chris MasonNov 1, 2005
  45. Catalin MarinasNov 1, 2005
  46. Chris MasonNov 1, 2005
  47. Catalin MarinasNov 1, 2005
  48. Chris MasonNov 2, 2005
  49. Catalin MarinasNov 5, 2005
  50. Petr BaudisNov 9, 2005
  51. Pavel MachekNov 10, 2005
  52. Catalin MarinasNov 10, 2005
  53. Chris MasonNov 1, 2005
  54. Linus TorvaldsNov 1, 2005
  55. Catalin MarinasNov 1, 2005
  56. Catalin MarinasNov 1, 2005
  57. Chris MasonNov 1, 2005
  58. Catalin MarinasNov 1, 2005
  59. Daniel BarkalowNov 1, 2005
  60. Linus TorvaldsOct 31, 2005
  61. wa1ter@myrealbox.comOct 31, 2005

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.