Bug (?) in hg diff output

Jonathan S. Shapiro shap at eros-os.com
Thu May 8 13:00:02 CDT 2008


I just noticed that "hg diff .", when run from within a workspace
subdirectory, generates paths relative to the workspace root. I found
this surprising. It would be very convenient if the sequence:

   hg diff relative-path > patches
   patch -R < patches
   patch < patches

would work without any "-p" options to the patch command.

Should the current behavior be considered a misfeature?

Yes, I understand why choosing the "right" common path prefix is hard,
and why a relative path involving ".." is a pain in the butt here.


shap



More information about the Mercurial-devel mailing list