summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Remote/WebDAV.hs15
-rw-r--r--debian/changelog2
-rw-r--r--debian/control2
-rw-r--r--git-annex.cabal2
4 files changed, 8 insertions, 13 deletions
diff --git a/Remote/WebDAV.hs b/Remote/WebDAV.hs
index 0611a3e56..391027d78 100644
--- a/Remote/WebDAV.hs
+++ b/Remote/WebDAV.hs
@@ -14,8 +14,6 @@ import qualified Data.Map as M
import qualified Data.ByteString.UTF8 as B8
import qualified Data.ByteString.Lazy.UTF8 as L8
import qualified Data.ByteString.Lazy as L
-import qualified Data.Text.Lazy as LT
-import qualified Text.XML as XML
import Network.URI (normalizePathSegments)
import qualified Control.Exception as E
import Network.HTTP.Conduit (HttpException(..))
@@ -109,8 +107,8 @@ storeHelper r k baseurl user pass b = catchBoolIO $ do
void $ catchMaybeHttp (deleteContent desturl user pass)
davMkdir (urlParent desturl) user pass
moveContent srcurl (B8.fromString desturl) user pass
- storehttp url v = putContentAndProps url user pass
- (noProps, (contentType, v))
+ storehttp url v = putContent url user pass
+ (contentType, v)
retrieveCheap :: Remote -> Key -> FilePath -> Annex Bool
retrieveCheap _ _ _ = return False
@@ -293,8 +291,8 @@ testDav :: String -> Maybe CredPair -> Annex ()
testDav baseurl (Just (u, p)) = do
showSideAction "testing WebDAV server"
test "make directory" $ davMkdir baseurl user pass
- test "write file" $ putContentAndProps testurl user pass
- (noProps, (contentType, L.empty))
+ test "write file" $ putContent testurl user pass
+ (contentType, L.empty)
test "delete file" $ deleteContent testurl user pass
where
test desc a = liftIO $
@@ -311,11 +309,6 @@ testDav _ Nothing = error "Need to configure webdav username and password."
contentType :: Maybe B8.ByteString
contentType = Just $ B8.fromString "application/octet-stream"
-{- The DAV library requires that properties be specified when storing a file.
- - This just omits any real properties. -}
-noProps :: XML.Document
-noProps = XML.parseText_ XML.def $ LT.pack "<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n<propertyupdate/>"
-
getCreds :: RemoteConfig -> UUID -> Annex (Maybe CredPair)
getCreds c u = getRemoteCredPairFor "webdav" c (davCreds u)
diff --git a/debian/changelog b/debian/changelog
index cfcf3de00..1491154b8 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -13,6 +13,8 @@ git-annex (3.20121128) UNRELEASED; urgency=low
associated with a file.
* webapp: S3 and Glacier forms now have a select list of all
currently-supported AWS regions.
+ * webdav: Avoid trying to set props, avoiding incompatability with
+ livedrive.com. Needs DAV version 0.3.
-- Joey Hess <joeyh@debian.org> Wed, 28 Nov 2012 13:31:07 -0400
diff --git a/debian/control b/debian/control
index f49c66c66..f1f4d82b0 100644
--- a/debian/control
+++ b/debian/control
@@ -13,7 +13,7 @@ Build-Depends:
libghc-http-dev,
libghc-utf8-string-dev,
libghc-hs3-dev (>= 0.5.6),
- libghc-dav-dev (>= 0.2),
+ libghc-dav-dev (>= 0.3),
libghc-testpack-dev,
libghc-quickcheck2-dev,
libghc-monad-control-dev (>= 0.3),
diff --git a/git-annex.cabal b/git-annex.cabal
index de966b555..34d5c7881 100644
--- a/git-annex.cabal
+++ b/git-annex.cabal
@@ -73,7 +73,7 @@ Executable git-annex
CPP-Options: -DWITH_S3
if flag(WebDAV)
- Build-Depends: DAV (>= 0.2), http-conduit, xml-conduit
+ Build-Depends: DAV (>= 0.3), http-conduit, xml-conduit
CPP-Options: -DWITH_WEBDAV
if flag(Assistant) && ! os(windows) && ! os(solaris)