fixed an oversight that had always prevented annex.resolvemerge from being honored...
authorJoey Hess <joeyh@joeyh.name>
Fri, 20 Dec 2019 14:55:23 +0000 (10:55 -0400)
committerJoey Hess <joeyh@joeyh.name>
Fri, 20 Dec 2019 15:00:08 +0000 (11:00 -0400)
forgot to add it to the merge function

CHANGELOG
Config/GitConfig.hs
Logs/Config.hs
Types/GitConfig.hs

index 8ed28ad1571323605280b8516a5234e922ca9f09..e748e4e7ea62fed9ca90f87024ce5603a08653e3 100644 (file)
--- a/CHANGELOG
+++ b/CHANGELOG
@@ -5,6 +5,8 @@ git-annex (7.20191219) UNRELEASED; urgency=medium
     like get also sped up in cases where they have to check a lot of
     files but only transfer a few files. Speedups range from 30-100%.
   * Added build dependency on the filepath-bytestring library.
+  * Fixed an oversight that had always prevented annex.resolvemerge
+    from being honored, when it was configured by git-annex config.
 
  -- Joey Hess <id@joeyh.name>  Wed, 18 Dec 2019 15:12:40 -0400
 
index 5795129feecbe0cff9d3f8a0611914171a6406f2..2df0525cd8517950221468d21d48c19c6219d4ee 100644 (file)
@@ -15,7 +15,10 @@ import Logs.Config
 
 {- Gets a specific setting from GitConfig. If necessary, loads the
  - repository-global defaults when the GitConfig does not yet 
- - have a value. -}
+ - have a value.
+ -
+ - Note: Be sure to add the config value to mergeGitConfig.
+ -}
 getGitConfigVal :: (GitConfig -> Configurable a) -> Annex a
 getGitConfigVal f = do
        v <- f <$> Annex.getGitConfig
index 1271c9826ca7f103c233bcffc30be2997255ee91..2369eac3c4d1eba8396f969ad297f734fa5d7c7d 100644 (file)
@@ -46,6 +46,7 @@ unsetGlobalConfig name = do
                setGlobalConfig' name (ConfigValue mempty)
 
 -- Reads the global config log every time.
+-- It's more efficient to use Config.GitConfig.
 getGlobalConfig :: ConfigKey -> Annex (Maybe ConfigValue)
 getGlobalConfig name = M.lookup name <$> loadGlobalConfig
 
index df2cd6bb1f4a83ddc62f3d847fef813f810465f1..2ad194bb9822cea02dd2f643335a0866577a2b93 100644 (file)
@@ -221,6 +221,7 @@ mergeGitConfig :: GitConfig -> GitConfig -> GitConfig
 mergeGitConfig gitconfig repoglobals = gitconfig
        { annexAutoCommit = merge annexAutoCommit
        , annexSyncContent = merge annexSyncContent
+       , annexResolveMerge = merge annexResolveMerge
        }
   where
        merge f = case f gitconfig of