Re: [PATCH v2] config: add --comment option to add a comment
- From
- Dragan Simic <dsimic@manjaro.org>
- Date
- Mar 11, 2024, 17:34 UTC
- Message-ID
- <dd818f1709834ca6cb9050fb4ad0f4ea@manjaro.org>
- In-Reply-To
- <xmqqr0ggsmmw.fsf@gitster.g>
On 2024-03-11 18:29, Junio C Hamano wrote:
Show 22 quoted lines
> Dragan Simic <dsimic@manjaro.org> writes: >> On 2024-03-11 13:55, Junio C Hamano wrote: >>> "Ralph Seichter via GitGitGadget" <gitgitgadget@gmail.com> writes: >>> >>>> From: Ralph Seichter <github@seichter.de> >>>> Introduce the ability to append comments to modifications >>>> made using git-config. Example usage: >>>> git config --comment "changed via script" \ >>>> --add safe.directory /home/alice/repo.git >>>> based on the proposed patch, the output produced is: >>>> [safe] >>>> directory = /home/alice/repo.git #changed via script >>> For readability, you probably would want to have a SP before the >>> given string, i.e., >>> variable = "value" # message comes here >> >> Let me interject... Perhaps also a tab character before the "# >> comment", >> instead of a space character. That would result in even better >> readability. > > Depends on your screen width ;-)
Ah, screens are pretty wide these days. :)
> If you were trying to tell me that SP or no SP is merely a personal > preference with the comment, I think you succeeded in doing so.
Huh, that wasn't my intention. IMHO, a space character between "#" and the actual comment is pretty much mandatory.