summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--doc/forum/pre-commit_hook_to_use_git_annex_for_only_large_files/comment_1_01db183b1f1d081066d88332e2b6166a._comment15
1 files changed, 15 insertions, 0 deletions
diff --git a/doc/forum/pre-commit_hook_to_use_git_annex_for_only_large_files/comment_1_01db183b1f1d081066d88332e2b6166a._comment b/doc/forum/pre-commit_hook_to_use_git_annex_for_only_large_files/comment_1_01db183b1f1d081066d88332e2b6166a._comment
new file mode 100644
index 000000000..98618cd51
--- /dev/null
+++ b/doc/forum/pre-commit_hook_to_use_git_annex_for_only_large_files/comment_1_01db183b1f1d081066d88332e2b6166a._comment
@@ -0,0 +1,15 @@
+[[!comment format=mdwn
+ username="joey"
+ subject="""comment 1"""
+ date="2015-05-05T18:46:42Z"
+ content="""
+The problem with this pre-commit hook is that by the time you run `git add
+largfile`, it has copied it into the git repository. Your hook will prevent
+it getting into a commit, so the repository will eventually garbage collect
+the copy away, but this can take some time or manual work to do.
+
+Recent versions of `git-annex add` will look at the annex.largefiles
+configuration and if the file does not match, add it to git directly.
+So that's an alternate workflow, where you `git annex add` files and let
+git-annex decide whether to put them in the annex or the git repository.
+"""]]