On Sun, Feb 6, 2011 at 12:36, Brendan Cully
On Sunday, 06 February 2011 at 12:13, Brett Cannon wrote:
On Sun, Feb 6, 2011 at 08:15, Antoine Pitrou
wrote: On Sun, 06 Feb 2011 02:10:15 +0100 brett.cannon
wrote: To create your patch, you should generate a unified diff from your checkout's top-level directory::
- svn diff > patch.diff + hg outgoing --path > patch.diff
Should be --patch. The problem is that it will show one several patch per changeset, which is normally not what you want (it's a pity "hg out" doesn't have an option to collapse them all).
Yeah, that is a perk of mq.
If your work needs some new files to be added to the source tree, remember -to ``svn add`` them before generating the patch:: +to ``hg add`` them before generating the patch::
- svn add Lib/newfile.py - svn diff > patch.diff + hg add Lib/newfile.py + hg outgoing --patch > patch.diff
You should commit before using "outgoing", otherwise the added file is not in the repo (and therefore not in the patch).
The problem with hg (and other DVCSes) is that allows for *several* local workflows, and therefore it's harder to advocate one of them in such tutorial docs. I wonder what Georg and Dirkjan suggest.
I just happened to see this message and don't really know the context -- you may not want to use any extensions here. But my 'rdiff' extension does let you create diffs between your working directory and upstream, and collapses your changesets into a single diff.
I would rather not have new hg users have to install an extension just to get a simple workflow going.