From: Junio C Hamano Date: Fri, 21 Dec 2012 23:18:31 +0000 (-0800) Subject: Merge branch 'nd/index-format-doc' X-Git-Tag: v1.8.1-rc3~9 X-Git-Url: https://git.lorimer.id.au/gitweb.git/diff_plain/d34ccd6df743222d1bc135edd15504be93b2571b?hp=-c Merge branch 'nd/index-format-doc' * nd/index-format-doc: index-format.txt: clarify what is "invalid" --- d34ccd6df743222d1bc135edd15504be93b2571b diff --combined Documentation/technical/index-format.txt index 57d6f915b1,ce28a7a6c3..7324154838 --- a/Documentation/technical/index-format.txt +++ b/Documentation/technical/index-format.txt @@@ -1,7 -1,7 +1,7 @@@ GIT index format ================ -= The git index file has the following format +== The git index file has the following format All binary numbers are in network byte order. Version 2 is described here unless stated otherwise. @@@ -161,8 -161,9 +161,9 @@@ this span of index as a tree. An entry can be in an invalidated state and is represented by having - -1 in the entry_count field. In this case, there is no object name - and the next entry starts immediately after the newline. + a negative number in the entry_count field. In this case, there is no + object name and the next entry starts immediately after the newline. + When writing an invalid entry, -1 should always be used as entry_count. The entries are written out in the top-down, depth-first order. The first entry represents the root level of the repository, followed by the