Re: [PATCH v4 8/8] ci/style-check: add `RemoveBracesLLVM` to '.clang-format'
- From
Karthik Nayak <karthik.188@gmail.com>
- Date
- Jul 15, 2024, 19:33 UTC
- Message-ID
- <CAOLa=ZToNFn5FvC0DDcx4V0tEgruSt1igDEunqZjkUiJCexQbA@mail.gmail.com>
- In-Reply-To
- <xmqq8qy24mil.fsf@gitster.g>
Junio C Hamano <gitster@pobox.com> writes:
Show 13 quoted lines
> Karthik Nayak <karthik.188@gmail.com> writes: > >> A more ideal solution would be if 'clang-format' allowed us to append >> rules to the existing '.clang-format' when invoked. But such an option >> does not exist. Since modifying the in-tree '.clang-format' is only done >> on the CI job for style-check and doesn't affect any other jobs and is >> not persisted in any ways, this hack should be okay. > > I think our mails crossed, but I do not know why this hack is OK. > Are there other CI jobs that muck with tracked files in the working > tree? > > Thanks.
I mean from an operation of a CI job, the repository is discarded after the job. So there isn't a problem with murking with the working tree.
But I agree to your latest response [1], it would be best to do this with a temporary file outside the working tree.
Will send a new version soon! Thanks
[1]: https://lore.kernel.org/r/xmqqle224npf.fsf@gitster.g