Re: [PATCH 3/4 v8] Let core.attributesfile default to $XDG_CONFIG_HOME/git/ignore
- From
Junio C Hamano <gitster@pobox.com>
- Date
- Jun 22, 2012, 21:20 UTC
- Message-ID
- <7v4nq3niwc.fsf@alter.siamese.dyndns.org>
- In-Reply-To
- <1340355806-6894-4-git-send-email-Matthieu.Moy@imag.fr>
Matthieu Moy <Matthieu.Moy@imag.fr> writes:
Show 17 quoted lines
> From: Huynh Khoi Nguyen Nguyen <Huynh-Khoi-Nguyen.Nguyen@ensimag.imag.fr>
>
> To use the feature of core.attributesfile, the user needs:
>
> 1. to create such a file,
>
> 2. and add configuration variable to point at it.
>
> Instead, we can make this a one-step process by choosing a default value
> which points to a filename in the user's $HOME, that is unlikely to
> already exist on the system, and only use the presence of the file as a
> cue that the user wants to use that feature.
>
> We use "${XDG_CONFIG_HOME:-$HOME/.config/git}/ignore" as a default value.
> It goes in the same directory as the newly added configuration
> file ("${XDG_CONFIG_HOME:-$HOME/.config/git}/config), and follows the XDG
> specification.The patch text may be OK but look at the Subject: line and notice something funny ;-)
Given the root cause of that "something funny", I'll reduce the log message of this one down to:
Let core.attributesfile default to $XDG_CONFIG_HOME/git/attributes
This gives the default value for the core.attributesfile variable
following the exact same logic of the previous change for the
core.excludesfile setting.
Signed-off-by: Huynh Khoi Nguyen Nguyen <Huynh-Khoi-Nguyen.Nguyen@ensimag.imag.fr>
...
Signed-off-by: Junio C Hamano <gitster@pobox.com>I am not sure about use of git/ignore in [2/2], though.
Shouldn't the default value for core.excludesfile be git/exclude, not git/ignore?