git-annex/doc/bugs/unannex_vs_unlock_hook_confusion.mdwn
Joey Hess c77ac11acc unannex: Commit staged changes at end
to avoid some confusing behavior with the pre-commit hook, which would see
some types of commits after an unannex as checking in of an unlocked file.
2011-02-01 21:27:23 -04:00

15 lines
746 B
Markdown

See [[forum/unannex_alternatives]] for problem description.
If an unannex is followed by a "git add; git commit", git-annex's hook thinks
that you have used git annex unlock on the file and are
now committing a changed version, and the right thing to do there is to add the
new content to the annex and update the symlink accordingly.
Can we tell the difference between an unannexed file that has yet to be committed
and has been re-added as a normal file, vs an unlocked file? --[[Joey||
> Hmm, not really. An unannexed file's content will have been dropped from
> the backend, but that's about the only difference. Perhaps unannex should
> just commit the removal of the file itself? --[[Joey]]
> [[done]], staged changes committed at end.