Re: [PATCH 0/2] Documentation updates for SHA-256
- From
Derrick Stolee <stolee@gmail.com>
- Date
- Aug 14, 2020, 02:33 UTC
- Message-ID
- <da077fb0-14bb-b84f-c526-d759ebc9f5eb@gmail.com>
- In-Reply-To
- <20200813224901.2652387-1-sandals@crustytoothpaste.net>
On 8/13/2020 6:48 PM, brian m. carlson wrote:
> As was pointed out recently, some of our documentation doesn't properly > reflect the new support for SHA-256.
Just to bring up some subtlety in Martin's message [1], there is some valid concern that the existing file formats are not correctly versioned "in a vacuum." When they are in a repository that has SHA-256 set as its hash algorithm, Git interprets these file formats correctly, but if a *.pack file (and its *.idx) happened to be copied into the pack directory of a Git repository still in SHA-1 mode, then Git would get confused and probably fail miserably.
Is that really a concern? Maybe, but also Git will never move data like that. The main thing is to focus on compatibility of the .git directory as a whole (and the protocol, as we move into inter-operability mode).
[1] https://lore.kernel.org/git/CAN0heSptiJL9d86ZeNPMUaZeTA68juwTyf3K-uWR=K-vt=1Hrg@mail.gmail.com/
> This series updates the pack and > index documentation to reflect that these formats can handle SHA-256, > and updates the transition plan to reflect what we've implemented and > what the next steps are.
These patches are good to help clarify these formats in the new world.
Thanks, -Stolee