diff options
-rw-r--r-- | Annex/StandardGroups.hs (renamed from Annex/Groups.hs) | 10 | ||||
-rw-r--r-- | Logs/PreferredContent.hs | 2 |
2 files changed, 10 insertions, 2 deletions
diff --git a/Annex/Groups.hs b/Annex/StandardGroups.hs index 3b4449514..e94185fbf 100644 --- a/Annex/Groups.hs +++ b/Annex/StandardGroups.hs @@ -5,7 +5,12 @@ - Licensed under the GNU GPL version 3 or higher. -} -module Annex.Groups where +module Annex.StandardGroups where + +import Common.Annex +import Logs.Group + +import qualified Data.Set as S data StandardGroup = ClientGroup | TransferGroup | ArchiveGroup | BackupGroup @@ -28,3 +33,6 @@ preferredContent ClientGroup = "exclude=*/archive/*" preferredContent TransferGroup = "not inallgroup=client and " ++ preferredContent ClientGroup preferredContent ArchiveGroup = "not copies=archive:1" preferredContent BackupGroup = "" -- all content is preferred + +setStandardGroup :: UUID -> StandardGroup -> Annex () +setStandardGroup u = groupSet u . S.singleton . fromStandardGroup diff --git a/Logs/PreferredContent.hs b/Logs/PreferredContent.hs index 8fdfef1fd..e31aa7bae 100644 --- a/Logs/PreferredContent.hs +++ b/Logs/PreferredContent.hs @@ -25,10 +25,10 @@ import Logs.UUIDBased import Limit import qualified Utility.Matcher import Annex.UUID -import Annex.Groups import Git.FilePath import Types.Group import Logs.Group +import Annex.StandardGroups {- Filename of preferred-content.log. -} preferredContentLog :: FilePath |