uninit: Clear annex.uuid from .git/config. Closes: #670639
This commit is contained in:
parent
a2ee4386bb
commit
e0b7012ccc
3 changed files with 11 additions and 2 deletions
|
@ -16,12 +16,14 @@ module Annex.UUID (
|
|||
getRepoUUID,
|
||||
getUncachedUUID,
|
||||
prepUUID,
|
||||
genUUID
|
||||
genUUID,
|
||||
removeRepoUUID,
|
||||
) where
|
||||
|
||||
import Common.Annex
|
||||
import qualified Git
|
||||
import qualified Git.Config
|
||||
import qualified Git.Command
|
||||
import qualified Build.SysConfig as SysConfig
|
||||
import Config
|
||||
|
||||
|
@ -61,6 +63,10 @@ getRepoUUID r = do
|
|||
when (g /= r) $ storeUUID cachekey u
|
||||
cachekey = remoteConfig r "uuid"
|
||||
|
||||
removeRepoUUID :: Annex ()
|
||||
removeRepoUUID = inRepo $ Git.Command.run "config"
|
||||
[Param "--unset", Param configkey]
|
||||
|
||||
getUncachedUUID :: Git.Repo -> UUID
|
||||
getUncachedUUID = toUUID . Git.Config.get configkey ""
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue