Is there anything in mercurial to 'parameterise' values in a file?
Steve Fink
sphink at gmail.com
Sat Feb 13 22:00:39 UTC 2021
Fair enough. I should mention that personally I've kind of moved to the
conclusion that cvs-like keywords are just not a good idea. Even in CVS
days when things were much simpler, it somehow always managed to create
more problems than it resolved. It is possible that better tooling could
change my mind.
That's for files that are checked in. I have no particular issue with, and
kinda like, embedding things in generated files. Including object files,
even if it means making up your own ELF section name. I've even been
tempted to have the build process put the entire output of `hg diff` into
the generated binary.
On Sat, Feb 13, 2021 at 9:09 AM Marcin Kasperski <
Marcin.Kasperski at mekk.waw.pl> wrote:
> Steve Fink <sphink at gmail.com> writes:
>
> > I also see a 'keyword' extension that might do what you want.
> >
> > `hg help keyword`
>
> No, it won't. Whatever you want. Seriously. I tried using keyword a few
> times and absolutely always it was major PITA. Unexpected conflicts,
> unexpected merges, unexpected update failures, accidental commits
> of expanded values, accidental distribution of unexpanded…
>
> Note: I am of course biased, because I finally developed alternative
> solution¹ to the specific problem of version-number/cvs-like-keywords/…
> But it was preceded by intensive and painful attempts to use keyword.
>
> ¹ https://pypi.org/project/mercurial_update_version/
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mercurial-scm.org/pipermail/mercurial/attachments/20210213/89df175d/attachment-0002.html>
More information about the Mercurial
mailing list