git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: Configuring a third-party git hook

From
Chris Angelico <rosuav@gmail.com>
Date
Mar 20, 2014, 16:51 UTC
Message-ID
<CAPTjJmpAcmVGgJK8iUvFuXJq_ZukisRZ6OD9TM=feuxDYm5iPQ@mail.gmail.com>
In-Reply-To
<CAO54GHC1B6hj-OvibHn2=-B25Xd5EmfWsphJ1S7vE4bgUUX3Bw@mail.gmail.com>
On Thu, Mar 20, 2014 at 11:53 PM, Kevin <ikke@ikke.info> wrote:
Show 9 quoted lines
> On Wed, Mar 19, 2014 at 12:16 PM, Chris Angelico <rosuav@gmail.com> wrote:
>> Two parts to the question, then. Firstly, is it acceptable to use 'git
>> config' for a hook like this? And secondly, either: Is there a naming
>> convention to follow? or, what alternative would you recommend?
>
> 1. I would say yes. git config is made to be extended and doesn't
> require a config item to be known.
> 2. Namespacing the config items like you did is a good thing to do so
> it won't interfere with other options.
Excellent! Thank you.

Is this documented anywhere? The git config man page says to look to other git man pages:

https://www.kernel.org/pub/software/scm/git/docs/git-config.html#_variables

A comment there to the effect that "Third party tools may also define their own variables" or something would make it clear that this is the intention.

ChrisA
Previous: KevinNext: Jeff King
Message 3 of 14 in “Configuring a third-party git hook”
  1. Chris AngelicoMar 19, 2014
  2. KevinMar 20, 2014
  3. Chris AngelicoMar 20, 2014
  4. Jeff KingMar 20, 2014
  5. Chris AngelicoMar 20, 2014
  6. Jeff KingMar 21, 2014
  7. Chris AngelicoMar 21, 2014
  8. Junio C HamanoMar 21, 2014
  9. Chris AngelicoMar 21, 2014
  10. Jeff KingMar 21, 2014
  11. Junio C HamanoMar 21, 2014
  12. Junio C HamanoMar 21, 2014
  13. Junio C HamanoMar 20, 2014
  14. Chris AngelicoMar 20, 2014

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.