add key to FileInfo

MatchingKey is not the thing to use when matching on actual worktreee
files.

Fix reversion in 8.20201116 that made include= and exclude= in
preferred/required content expressions match a path relative to the current
directory, rather than the path from the top of the repository.
This commit is contained in:
Joey Hess 2020-12-14 17:42:02 -04:00
parent 205a837e8a
commit 01527b21d8
No known key found for this signature in database
GPG key ID: DB12DB0FF05F8F38
13 changed files with 48 additions and 13 deletions

View file

@ -194,3 +194,5 @@ Yes, so far it has worked nicely archiving (and describing via git-annex metadat
orderly fashion.
[[!meta author=jkniiv]]
> [[fixed|done]] --[[Joey]]

View file

@ -0,0 +1,18 @@
[[!comment format=mdwn
username="joey"
subject="""comment 1"""
date="2020-12-14T19:36:20Z"
content="""
Looks like it was caused by [[!commit d032b0885d80d12c00fa8813e88deab1631eef8a]] which made MatchingKey be used
rather than MatchingFile. Which oops, mean the filename is left relative rather
than being made into a path from the top of the repo.
Fixed that and your test case works. I do think this would be a better
expression for you to use though:
(include=*.mrimg and exclude=*/arkistoidut/* and exclude=arkistoidut/*)
Or maybe just exclude=arkistoidut/* rather than both, depending on if you
want to support subdirectories of subdirectories with that name, or only
the single subdirectory in the top of your repo.
"""]]