starting support for remote.name.annexUrl set to annex+http

In this case, Remote.Git should not use that url for all access to
the repository. It will only be used for annex operations, which isn't
done yet.
This commit is contained in:
Joey Hess 2024-07-23 09:12:21 -04:00
parent fdb888a56a
commit 5c39652235
No known key found for this signature in database
GPG key ID: DB12DB0FF05F8F38
5 changed files with 30 additions and 8 deletions

View file

@ -13,6 +13,7 @@ module Command.P2PHttp where
import Command
import P2P.Http
import P2P.Http.Url
import qualified P2P.Protocol as P2P
import Annex.Url
import Utility.Env
@ -79,7 +80,9 @@ seek o = getAnnexWorkerPool $ \workerpool -> do
mkGetServerMode authenv o
Warp.run (fromIntegral port) (p2pHttpApp st)
where
port = fromMaybe (fromIntegral defaultHttpProtocolPort) (portOption o)
port = fromMaybe
(fromIntegral defaultP2PHttpProtocolPort)
(portOption o)
mkGetServerMode :: M.Map Auth P2P.ServerMode -> Options -> GetServerMode
mkGetServerMode _ o _ Nothing