Re: Issue when changing staged files in a pre-commit hook
- From
Junio C Hamano <gitster@pobox.com>
- Date
- Jan 19, 2016, 18:44 UTC
- Message-ID
- <xmqq1t9dbe9y.fsf@gitster.mtv.corp.google.com>
- In-Reply-To
- <CACsJy8DhiYiie7+Cw3PkPJpSX7CGp-r2Mu98mLp4OMhhGdsXgQ@mail.gmail.com>
Duy Nguyen <pclouds@gmail.com> writes:
> I think it's the intended behavior.
Yeah, pre-commit was designed for inspecting and rejecting, not for tweaking and munging. Perhaps "git commit" can be tightened to make sure that pre-commit that returns successfully did not muck with the working tree and the index?