]> arthur.barton.de Git - bup.git/commit
cmd-index: correct reporting of deleted vs. added vs. modified status.
authorAvery Pennarun <apenwarr@gmail.com>
Sun, 10 Jan 2010 00:07:05 +0000 (19:07 -0500)
committerAvery Pennarun <apenwarr@gmail.com>
Sun, 10 Jan 2010 00:09:34 +0000 (19:09 -0500)
commit03c97d47ac6f37d70caf74b3be3d08f3eff9272c
treecb849e33dcf65872237d803f03789ff86cace8ec
parent733f677c1afc54ac4b6454bc34fe2f76bff9e0c0
cmd-index: correct reporting of deleted vs. added vs. modified status.

A file with an all-zero sha1 is considered Added instead of Modified, since
it has obviously *never* had a valid sha1.  (A modified file has an old
sha1, but IX_HASHVALID isn't set.)

We also now don't remove old files from the index - for now - so that we can
report old files with a D status.  This might perhaps be useful eventually.

Furthermore, we had a but where reindexing a particular filename would
"sometimes" cause siblings of that file to be marked as deleted.  The
sibling entries should never be updated, because we didn't check them and
thus have no idea of their new status.  This bug was mostly caused by the
silly way we current pass dirnames and filenames around...
cmd-index.py