From: Junio C Hamano <gitster@pobox.com>
To: "Maksym Sobolyev via GitGitGadget" <gitgitgadget@gmail.com>
Cc: git@vger.kernel.org, Maksym Sobolyev <sobomax@gmail.com>,
Maksym Sobolyev <sobomax@sippysoft.com>
Subject: Re: [PATCH] Make ident dynamic, not just a hardcoded value of "$Id".
Date: Mon, 23 Aug 2021 11:10:11 -0700 [thread overview]
Message-ID: <xmqqa6l8qbgc.fsf@gitster.g> (raw)
In-Reply-To: <pull.1074.git.git.1629736918861.gitgitgadget@gmail.com> (Maksym Sobolyev via GitGitGadget's message of "Mon, 23 Aug 2021 16:41:58 +0000")
"Maksym Sobolyev via GitGitGadget" <gitgitgadget@gmail.com> writes:
> From: Maksym Sobolyev <sobomax@sippysoft.com>
>
> This allows ident to be something like $FreeBSD$ so it provides matching
> functionality for repos migrated from CVS / SVN.
>
> This works by allowing ident to have a parameter, i.e.:
>
> * ident=MyCustomId
>
> In .gitattributes.
I would have expected that, just like cvs uses its configuration
mechanism for LocalKeyword, this would belong to the .git/config
file.
The attribute mechanism is inherently for stuff that you would want
to specify per-path, so the "do we do keyword expansion for this
file (yes/no)?" is a good match to be an attribute, and that
question is what the original 'ident' attribute asks.
I do not think "what keyword do we want to expand as if it were
$Id$?" is a question we want to be giving different answers per
path, and it does not smell like a good match to be an attribute.
By allowing a potentially separate values for
*.txt ident=FreeBSD
*.cc ident=OpenBSD
this gives long rope to create a mess to the users.
I also think that the ident expansion is overrated, and have a
feeling that we should discourage its use, not encourage it, but
that is a separate story.
Thanks.
next prev parent reply other threads:[~2021-08-23 18:10 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-08-23 16:41 [PATCH] Make ident dynamic, not just a hardcoded value of "$Id" Maksym Sobolyev via GitGitGadget
2021-08-23 18:10 ` Junio C Hamano [this message]
2021-08-23 18:41 ` Philip Oakley
2021-08-26 4:28 ` [PATCH v2] " Maksym Sobolyev via GitGitGadget
2021-08-26 20:37 ` Matheus Tavares
2021-09-02 0:58 ` Junio C Hamano
2021-09-02 19:04 ` Junio C Hamano
2021-08-27 2:59 ` Junio C Hamano
[not found] ` <CABFYoQC_FzbU_E4hU0kCz-WFJNOLspwL2Gjc01sMXDZosxJWjw@mail.gmail.com>
2021-09-01 5:35 ` Junio C Hamano
2021-09-01 2:13 ` [PATCH v3] " Maksym Sobolyev via GitGitGadget
2021-09-02 3:40 ` Đoàn Trần Công Danh
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: http://vger.kernel.org/majordomo-info.html
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=xmqqa6l8qbgc.fsf@gitster.g \
--to=gitster@pobox.com \
--cc=git@vger.kernel.org \
--cc=gitgitgadget@gmail.com \
--cc=sobomax@gmail.com \
--cc=sobomax@sippysoft.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://80x24.org/mirrors/git.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).