templates and the log --debug output the extra fields
Uwe Brauer
oub at mat.ucm.es
Tue Jan 5 12:57:37 UTC 2021
>>> "SF" == Steve Fink <sphink at gmail.com> writes:
> On 1/3/21 7:48 AM, Uwe Brauer wrote:
>> Can anybody please point out to me the required syntax for this field?
> I've never played with this stuff before, but it was intriguing, and
> this seemed to work for the basic case when saved to a file
> /tmp/templatestuff:
> %include map-cmdline.default
> [templates]
> changeset =
> '{cset}{branches}{bookmarks}{ltopic}{tags}{parents}{luser}{ldate}{summary}{lfiles}\n'
> ltopic = "{if(get(extras, "topic"),label("log.topic",
> "topic: {get(extras, "topic")}\n"))}"
Thanks, this was what I was looking for!
> ----
> I ran with `hg log --style /tmp/templatestuff`. (You'd probably want to
> override changeset_verbose, changeset_brief, etc. as well.)
Yes I most likely only use ltopic
> I will also note that this kind of goes against the idea of topics, as
> things that only apply to draft revisions, and so I could imagine it
> breaking if stale topics were discarded at some time in the future. But
Well I use topic quite a bit, but sometimes find it useful to find out
which changesets belong(ed) to a certain topic. I hope this feature will
stay in the future, as I don't see any contradiction to the topic
philosophy.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/pkcs7-signature
Size: 5673 bytes
Desc: not available
URL: <http://lists.mercurial-scm.org/pipermail/mercurial/attachments/20210105/7458f535/attachment.p7s>
More information about the Mercurial
mailing list