chiark / gitweb /
split brain cache: Add a dummy ref update when necessary
git-update-ref does not make a new reflog entry if the ref is not
actually being changed.
This can mean that `dgit build' might fail to find a good cache entry,
but also fail to generate one that push will accept.
In this case, generate a dummy reflog update. We make a spurious
child of the $dgitview, as that's straightforward. Giving it the same
tree and a parent means that human use of reflog commands will produce
empty results rather than lots of confusing output.
Signed-off-by: Ian Jackson <ijackson@chiark.greenend.org.uk>