move dummy uuids to Annex.UUID
This commit is contained in:
parent
8d1e372a8b
commit
7e422269a6
9 changed files with 16 additions and 10 deletions
|
@ -23,6 +23,8 @@ module Annex.UUID (
|
|||
storeUUID,
|
||||
storeUUIDIn,
|
||||
setUUID,
|
||||
webUUID,
|
||||
bitTorrentUUID,
|
||||
) where
|
||||
|
||||
import Common.Annex
|
||||
|
@ -98,3 +100,11 @@ setUUID :: Git.Repo -> UUID -> IO Git.Repo
|
|||
setUUID r u = do
|
||||
let s = show configkey ++ "=" ++ fromUUID u
|
||||
Git.Config.store s r
|
||||
|
||||
-- Dummy uuid for the whole web. Do not alter.
|
||||
webUUID :: UUID
|
||||
webUUID = UUID "00000000-0000-0000-0000-000000000001"
|
||||
|
||||
-- Dummy uuid for bittorrent. Do not alter.
|
||||
bitTorrentUUID :: UUID
|
||||
bitTorrentUUID = UUID "00000000-0000-0000-0000-000000000002"
|
||||
|
|
|
@ -21,6 +21,7 @@ import Logs.Web
|
|||
import Logs.Presence
|
||||
import Logs.Location
|
||||
import Annex.Content
|
||||
import Annex.UUID
|
||||
import qualified Backend
|
||||
import qualified Types.Backend
|
||||
import qualified Types.Key
|
||||
|
|
|
@ -42,7 +42,6 @@ import Utility.Gpg
|
|||
import Annex.UUID
|
||||
import Assistant.Ssh
|
||||
import Config
|
||||
import Logs.Web (webUUID)
|
||||
|
||||
import qualified Data.Text as T
|
||||
import qualified Data.Map as M
|
||||
|
|
|
@ -22,6 +22,7 @@ import qualified Backend.URL
|
|||
import qualified Remote
|
||||
import qualified Types.Remote as Remote
|
||||
import Annex.Content
|
||||
import Annex.UUID
|
||||
import Logs.Web
|
||||
import Types.Key
|
||||
import Types.KeySource
|
||||
|
|
|
@ -30,6 +30,7 @@ import qualified Utility.Format
|
|||
import Utility.Tmp
|
||||
import Command.AddUrl (addUrlFile, downloadRemoteFile, relaxedOption)
|
||||
import Annex.Perms
|
||||
import Annex.UUID
|
||||
import Backend.URL (fromUrl)
|
||||
#ifdef WITH_QUVI
|
||||
import Annex.Quvi
|
||||
|
|
|
@ -10,6 +10,7 @@ module Command.RmUrl where
|
|||
import Common.Annex
|
||||
import Command
|
||||
import Logs.Web
|
||||
import Annex.UUID
|
||||
import qualified Remote
|
||||
|
||||
cmd :: [Command]
|
||||
|
|
|
@ -7,7 +7,6 @@
|
|||
|
||||
module Logs.Web (
|
||||
URLString,
|
||||
webUUID,
|
||||
getUrls,
|
||||
getUrlsWithPrefix,
|
||||
setUrlPresent,
|
||||
|
@ -35,10 +34,6 @@ import qualified Git
|
|||
import qualified Git.LsFiles
|
||||
import Utility.Url
|
||||
|
||||
-- Dummy uuid for the whole web. Do not alter.
|
||||
webUUID :: UUID
|
||||
webUUID = UUID "00000000-0000-0000-0000-000000000001"
|
||||
|
||||
{- Gets all urls that a key might be available from. -}
|
||||
getUrls :: Key -> Annex [URLString]
|
||||
getUrls key = do
|
||||
|
|
|
@ -23,15 +23,12 @@ import Utility.Metered
|
|||
import Utility.Tmp
|
||||
import Backend.URL
|
||||
import Annex.Perms
|
||||
import Annex.UUID
|
||||
import qualified Annex.Url as Url
|
||||
|
||||
import qualified Data.Map as M
|
||||
import Network.URI
|
||||
|
||||
-- Dummy uuid for bittorrent. Do not alter.
|
||||
bitTorrentUUID :: UUID
|
||||
bitTorrentUUID = UUID "00000000-0000-0000-0000-000000000002"
|
||||
|
||||
remote :: RemoteType
|
||||
remote = RemoteType {
|
||||
typename = "bittorrent",
|
||||
|
|
|
@ -16,6 +16,7 @@ import qualified Git.Construct
|
|||
import Annex.Content
|
||||
import Config.Cost
|
||||
import Logs.Web
|
||||
import Annex.UUID
|
||||
import Types.Key
|
||||
import Utility.Metered
|
||||
import qualified Annex.Url as Url
|
||||
|
|
Loading…
Reference in a new issue