Re: Request: a way to ignore .gitattributes
- From
Junio C Hamano <gitster@pobox.com>
- Date
- Mar 12, 2022, 23:50 UTC
- Message-ID
- <xmqq8rten31r.fsf@gitster.g>
- In-Reply-To
- <01ab01d83656$071d7cd0$15587670$@nexbridge.com>
<rsbecker@nexbridge.com> writes:
Show 10 quoted lines
> These may seem a little off the wall, but: > 1. Could you use a clean/smudge approach to mess with your bad > .gitattributes file before it gets put down on disk? I realize that > registering the filter might not be possible given that you need to muck > with .gitattributes to do it, but if you have any control at all and can get > the filter in, perhaps that might be a way to clean up the bad > .gitattributes file. > 2. What about a post-checkout hook that fixes .gitattributes and then does > an update-index --assume-unchanged on it. This is under the assumption that > you will never change .gitattributes in your clone.
Ahh, that's cleverer than what I had initially as a knee-jerk reaction, which was "fix the tool that emits '$path -text' for each and every path in the repository and instead use '* -text' perhaps?".