annex.merge-annex-branches

Added annex.merge-annex-branches config setting which can be used to
disable automatic merge of git-annex branches.

I wonder if git-annex merge/sync/assistant should disable this
setting? Not sure yet, so have not done so. May be that users will not set
it in git config, but pass it via -c to commands that need it.

Checking the config setting adds a very small overhead, but it's
only checked once per command so should be insignificant.

This commit was supported by the NSF-funded DataLad project.
This commit is contained in:
Joey Hess 2018-02-22 14:25:32 -04:00
parent addb91b24b
commit 09e73a3ab6
No known key found for this signature in database
GPG key ID: DB12DB0FF05F8F38
6 changed files with 59 additions and 6 deletions

View file

@ -59,6 +59,7 @@ data GitConfig = GitConfig
, annexBloomAccuracy :: Maybe Int
, annexSshCaching :: Maybe Bool
, annexAlwaysCommit :: Bool
, annexMergeAnnexBranches :: Bool
, annexDelayAdd :: Maybe Int
, annexHttpHeaders :: [String]
, annexHttpHeadersCommand :: Maybe String
@ -116,6 +117,7 @@ extractGitConfig r = GitConfig
, annexBloomAccuracy = getmayberead (annex "bloomaccuracy")
, annexSshCaching = getmaybebool (annex "sshcaching")
, annexAlwaysCommit = getbool (annex "alwayscommit") True
, annexMergeAnnexBranches = getbool (annex "merge-annex-branches") True
, annexDelayAdd = getmayberead (annex "delayadd")
, annexHttpHeaders = getlist (annex "http-headers")
, annexHttpHeadersCommand = getmaybe (annex "http-headers-command")