diff options
author | Joey Hess <joeyh@joeyh.name> | 2018-09-24 12:07:46 -0400 |
---|---|---|
committer | Joey Hess <joeyh@joeyh.name> | 2018-09-24 12:10:18 -0400 |
commit | 4ecba916a14e02dd62f8ba4257db810fa859f017 (patch) | |
tree | 5dfdf3266289257046e8d6f53e25f58bccb849bb /Types | |
parent | 0f9eafc157af529c54f2b122882e5cf5cf18ed7d (diff) |
annex.maxextensionlength
Added annex.maxextensionlength for use cases where extensions longer than 4
characters are needed.
This commit was sponsored by Henrik Riomar on Patreon.
Diffstat (limited to 'Types')
-rw-r--r-- | Types/Backend.hs | 2 | ||||
-rw-r--r-- | Types/GitConfig.hs | 2 |
2 files changed, 3 insertions, 1 deletions
diff --git a/Types/Backend.hs b/Types/Backend.hs index f1d8919a49..10b7b47fc8 100644 --- a/Types/Backend.hs +++ b/Types/Backend.hs @@ -21,7 +21,7 @@ data BackendA a = Backend , canUpgradeKey :: Maybe (Key -> Bool) -- Checks if there is a fast way to migrate a key to a different -- backend (ie, without re-hashing). - , fastMigrate :: Maybe (Key -> BackendA a -> AssociatedFile -> Maybe Key) + , fastMigrate :: Maybe (Key -> BackendA a -> AssociatedFile -> a (Maybe Key)) -- Checks if a key is known (or assumed) to always refer to the -- same data. , isStableKey :: Key -> Bool diff --git a/Types/GitConfig.hs b/Types/GitConfig.hs index 31d6fbe411..0677c6dbd9 100644 --- a/Types/GitConfig.hs +++ b/Types/GitConfig.hs @@ -98,6 +98,7 @@ data GitConfig = GitConfig , annexAllowedUrlSchemes :: S.Set Scheme , annexAllowedHttpAddresses :: String , annexAllowUnverifiedDownloads :: Bool + , annexMaxExtensionLength :: Maybe Int , coreSymlinks :: Bool , coreSharedRepository :: SharedRepository , receiveDenyCurrentBranch :: DenyCurrentBranch @@ -171,6 +172,7 @@ extractGitConfig r = GitConfig getmaybe (annex "security.allowed-http-addresses") , annexAllowUnverifiedDownloads = (== Just "ACKTHPPT") $ getmaybe (annex "security.allow-unverified-downloads") + , annexMaxExtensionLength = getmayberead (annex "maxextensionlength") , coreSymlinks = getbool "core.symlinks" True , coreSharedRepository = getSharedRepository r , receiveDenyCurrentBranch = getDenyCurrentBranch r |