support findred and --branch with file matching options

* findref: Support file matching options: --include, --exclude,
  --want-get, --want-drop, --largerthan, --smallerthan, --accessedwithin
* Commands supporting --branch now apply file matching options --include,
  --exclude, --want-get, --want-drop to filenames from the branch.
  Previously, combining --branch with those would fail to match anything.
* add, import, findref: Support --time-limit.

This commit was sponsored by Jake Vosloo on Patreon.
This commit is contained in:
Joey Hess 2018-12-09 13:38:35 -04:00
parent 61b1f9deaf
commit 029ae8d4db
No known key found for this signature in database
GPG key ID: DB12DB0FF05F8F38
10 changed files with 54 additions and 26 deletions

View file

@ -8,7 +8,7 @@
module Types.FileMatcher where
import Types.UUID (UUID)
import Types.Key (Key)
import Types.Key (Key, AssociatedFile)
import Utility.Matcher (Matcher, Token)
import Utility.FileSize
@ -18,7 +18,7 @@ import qualified Data.Set as S
data MatchInfo
= MatchingFile FileInfo
| MatchingKey Key
| MatchingKey Key AssociatedFile
| MatchingInfo (OptInfo FilePath) (OptInfo Key) (OptInfo FileSize) (OptInfo MimeType)
type MimeType = String