set annex-config-uuid when RemoteConfig contains a sameas-uuid
Initremote sets that, so after both initremote and enableremote, the git config will be set. Any remote that does not use Annex.SpecialRemote won't set annex-config-uuid. But that's only Remote.Git, which doesn't use RemoteConfig anyway.
This commit is contained in:
parent
46071a2435
commit
92ff30df70
5 changed files with 45 additions and 24 deletions
|
@ -35,6 +35,7 @@ module Remote.Helper.Special (
|
|||
|
||||
import Annex.Common
|
||||
import qualified Annex
|
||||
import Annex.SpecialRemote.Config
|
||||
import Types.StoreRetrieve
|
||||
import Types.Remote
|
||||
import Crypto
|
||||
|
@ -72,6 +73,9 @@ gitConfigSpecialRemote u c cfgs = do
|
|||
forM_ cfgs $ \(k, v) ->
|
||||
setConfig (remoteConfig c k) v
|
||||
storeUUIDIn (remoteConfig c "uuid") u
|
||||
case M.lookup sameasUUIDKey c of
|
||||
Nothing -> noop
|
||||
Just sameasuuid -> setConfig (remoteConfig c "config-uuid") sameasuuid
|
||||
|
||||
-- RetrievalVerifiableKeysSecure unless overridden by git config.
|
||||
--
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue