diff options
author | http://joeyh.name/ <http://joeyh.name/@web> | 2014-02-06 17:05:46 +0000 |
---|---|---|
committer | admin <admin@branchable.com> | 2014-02-06 17:05:46 +0000 |
commit | 879f0e7da58337a4ebfb4a1bb059a69b3ddc96aa (patch) | |
tree | 02d1178bd160b5afbc500f4a9a6e7a1047782977 /doc | |
parent | 6d6b8c8c7e47b0fb4c2c5d018e9a18bf33d3caca (diff) |
Added a comment
Diffstat (limited to 'doc')
-rw-r--r-- | doc/forum/Locking_and_then_unlocking_a_file_results_in_file_changed_warning/comment_3_fd39e6ceffd9bf0709658c34945d8699._comment | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/doc/forum/Locking_and_then_unlocking_a_file_results_in_file_changed_warning/comment_3_fd39e6ceffd9bf0709658c34945d8699._comment b/doc/forum/Locking_and_then_unlocking_a_file_results_in_file_changed_warning/comment_3_fd39e6ceffd9bf0709658c34945d8699._comment new file mode 100644 index 000000000..5b23df870 --- /dev/null +++ b/doc/forum/Locking_and_then_unlocking_a_file_results_in_file_changed_warning/comment_3_fd39e6ceffd9bf0709658c34945d8699._comment @@ -0,0 +1,16 @@ +[[!comment format=mdwn + username="http://joeyh.name/" + ip="206.74.132.139" + subject="comment 3" + date="2014-02-06T17:05:45Z" + content=""" +Recent versions of git-annex have tried to extend the --force option to be needed in any operation that can possibly cause data loss. This includes locking a file, since that throws away any changes. + +Note that `git annex lock` does not check if the file is unmodified. For a few reasons including + +* some backends don't include a checksum +* it would be expensive to check a checksum +* the file could get modified after or during a checksum check, and those modifications would be missed + +If you are sure you want to throw away any changes, use --force as suggested. If not, use `git annex add $file`, and assuming you're using a checksumming backend, it will notice the file has not changed and do what you want `git annex lock $file` to have done in this case. +"""]] |