summaryrefslogtreecommitdiff
path: root/doc
diff options
context:
space:
mode:
authorGravatar Joey Hess <joeyh@joeyh.name>2016-02-03 16:29:34 -0400
committerGravatar Joey Hess <joeyh@joeyh.name>2016-02-03 16:29:34 -0400
commit590d47ed764c88a08f615c3af057cbff26633bc1 (patch)
tree4ea91c9c5cb34929df631fc74923ee8d5248471c /doc
parent3f1649ef32cb7f7597473dae6a0e92ff875cea45 (diff)
annex.largefiles: Add support for mimetype=text/* etc, when git-annex is linked with libmagic.
Diffstat (limited to 'doc')
-rw-r--r--doc/tips/largefiles.mdwn13
-rw-r--r--doc/todo/wishlist:_annex.largefiles_support_for_mimetypes.mdwn6
2 files changed, 19 insertions, 0 deletions
diff --git a/doc/tips/largefiles.mdwn b/doc/tips/largefiles.mdwn
index c07d7f3f2..40cd3eafb 100644
--- a/doc/tips/largefiles.mdwn
+++ b/doc/tips/largefiles.mdwn
@@ -50,6 +50,8 @@ The following terms can be used in annex.largefiles:
Specify files to include or exclude.
+ The glob can contain `*` and `?` to match arbitrary characters.
+
* `smallerthan=size` / `largerthan=size`
Matches only files smaller than, or larger than the specified size.
@@ -57,6 +59,17 @@ The following terms can be used in annex.largefiles:
The size can be specified with any commonly used units, for example,
"0.5 gb" or "100 KiloBytes"
+* `mimetype=glob`
+
+ Looks up the MIME type of a file, and checks if the glob matches it.
+
+ For example, "mimetype=text/*" will match many varieties of text files,
+ including "text/plain", but also "text/x-shellscript", "text/x-makefile",
+ etc.
+
+ This is only available to use when git-annex was built with the
+ MagicMime build flag.
+
* `anything`
Matches any file.
diff --git a/doc/todo/wishlist:_annex.largefiles_support_for_mimetypes.mdwn b/doc/todo/wishlist:_annex.largefiles_support_for_mimetypes.mdwn
index f38e41dd3..b64eb45cc 100644
--- a/doc/todo/wishlist:_annex.largefiles_support_for_mimetypes.mdwn
+++ b/doc/todo/wishlist:_annex.largefiles_support_for_mimetypes.mdwn
@@ -1 +1,7 @@
It would be nice to have mimetype support on the `annex.largefiles` configuration directive. F.e. `git config annex.largefiles "not mimetype=text/plain"`
+
+> [[done]]; Implemented support for mimetype=text/plain or even
+> mimetype=text/*
+>
+> Decided not to add external command test support, at least not for now.
+> --[[Joey]]