[PATCH 2 of 3] commit: add a -M/--reuse-message option to copy a commit message from a

Jordi GutiƩrrez Hermoso jhermoso at neurorx.com
Tue May 19 08:33:48 CDT 2015


On Fri, 2015-05-15 at 15:54 -0700, Tony Tung wrote:
> # HG changeset patch
> # User Tony Tung <tonytung at fb.com>
> # Date 1429655274 25200
> #      Tue Apr 21 15:27:54 2015 -0700
> # Node ID dc122dd80665762d8febe2db1a08ce00a63d5ab8
> # Parent  18cadf9d058931ef00e5272d15cb5cf2ebc3a248
> commit: add a -M/--reuse-message option to copy a commit message from a
> revspec

We don't have revspecs. That's a gitism with much very limited
functionality compared to what we do have have: revsets.

On Sat, 2015-05-16 at 00:06 -0700, Pierre-Yves David wrote:
> To conclude. given that (1) we can provide better option for the
> same effect, (2) there is already option to get this done today with
> "reasonable" cost (3) commit is a very critical command regarding UI
> bloat. I do not think the Utility/bloat ratio is good enough for
> this new flag.

I agree. It's already a big problem that `hg help rebase` is so long.
I intend to trim it.

Until `hg amend` lands in core, a simple fix that does not add UI
bloat is `hg commit --logfile .hg/last-message.txt`, perhaps with
--amend. This whole thinking that reusing commit messages has got
something to do with "resets" and "revspecs" seems to be trying to
transpose onto Mercurial a workflow that git's UI imposes.




More information about the Mercurial-devel mailing list