From f534fcc7b1a01f30e4ee41a0a364fe2cbf25d5a8 Mon Sep 17 00:00:00 2001 From: Joey Hess Date: Thu, 5 Jan 2012 23:14:10 -0400 Subject: [PATCH] remove S3stub stuff Let's keep that in a no-s3 branch, which can be merged into eg, debian-stable. --- Makefile | 15 ++------------- Remote.hs | 14 +++++++------- Remote/{S3real.hs => S3.hs} | 6 +++--- Remote/S3stub.hs | 7 ------- debian/changelog | 1 - doc/install.mdwn | 2 +- 6 files changed, 13 insertions(+), 32 deletions(-) rename Remote/{S3real.hs => S3.hs} (99%) delete mode 100644 Remote/S3stub.hs diff --git a/Makefile b/Makefile index 6805f93d2a..93d4567ec5 100644 --- a/Makefile +++ b/Makefile @@ -10,7 +10,7 @@ GHCMAKE=ghc $(GHCFLAGS) --make bins=git-annex git-annex-shell git-union-merge mans=git-annex.1 git-annex-shell.1 git-union-merge.1 -sources=Build/SysConfig.hs Utility/StatFS.hs Utility/Touch.hs Remote/S3.hs +sources=Build/SysConfig.hs Utility/StatFS.hs Utility/Touch.hs all=$(bins) $(mans) docs @@ -33,18 +33,7 @@ Build/SysConfig.hs: configure.hs Build/TestConfig.hs hsc2hs $< perl -i -pe 's/^{-# INCLUDE.*//' $@ -Remote/S3.hs: - @ln -sf S3real.hs Remote/S3.hs - -Remote/S3.o: Remote/S3.hs - @if ! $(GHCMAKE) Remote/S3.hs; then \ - ln -sf S3stub.hs Remote/S3.hs; \ - echo "** building without S3 support"; \ - fi - -sources: $(sources) - -$(bins): sources Remote/S3.o +$(bins): $(sources) $(GHCMAKE) $@ git-annex.1: doc/git-annex.mdwn diff --git a/Remote.hs b/Remote.hs index 8dd80d4191..8046175d27 100644 --- a/Remote.hs +++ b/Remote.hs @@ -55,14 +55,14 @@ import qualified Remote.Web import qualified Remote.Hook remoteTypes :: [RemoteType] -remoteTypes = catMaybes - [ Just Remote.Git.remote +remoteTypes = + [ Remote.Git.remote , Remote.S3.remote - , Just Remote.Bup.remote - , Just Remote.Directory.remote - , Just Remote.Rsync.remote - , Just Remote.Web.remote - , Just Remote.Hook.remote + , Remote.Bup.remote + , Remote.Directory.remote + , Remote.Rsync.remote + , Remote.Web.remote + , Remote.Hook.remote ] {- Builds a list of all available Remotes. diff --git a/Remote/S3real.hs b/Remote/S3.hs similarity index 99% rename from Remote/S3real.hs rename to Remote/S3.hs index 96a831e340..bef89b5539 100644 --- a/Remote/S3real.hs +++ b/Remote/S3.hs @@ -28,8 +28,8 @@ import Crypto import Annex.Content import Utility.Base64 -remote :: Maybe RemoteType -remote = Just $ RemoteType { +remote :: RemoteType +remote = RemoteType { typename = "S3", enumerate = findSpecialRemotes "s3", generate = gen, @@ -58,7 +58,7 @@ gen' r u c cst = hasKeyCheap = False, config = c, repo = r, - remotetype = fromJust remote + remotetype = remote } s3Setup :: UUID -> RemoteConfig -> Annex RemoteConfig diff --git a/Remote/S3stub.hs b/Remote/S3stub.hs deleted file mode 100644 index 5bd2b1c795..0000000000 --- a/Remote/S3stub.hs +++ /dev/null @@ -1,7 +0,0 @@ --- stub for when hS3 is not available -module Remote.S3 (remote) where - -import Types - -remote :: Maybe RemoteType -remote = Nothing diff --git a/debian/changelog b/debian/changelog index ac6e9b80c1..e5687aac14 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,7 +1,6 @@ git-annex (3.20120106) UNRELEASED; urgency=low * Support unescaped repository urls, like git does. - * Don't list S3 as a remote type when built without S3 support. -- Joey Hess Thu, 05 Jan 2012 14:29:30 -0400 diff --git a/doc/install.mdwn b/doc/install.mdwn index 3e89c67758..26af5a091d 100644 --- a/doc/install.mdwn +++ b/doc/install.mdwn @@ -30,7 +30,7 @@ To build and use git-annex, you will need: * [TestPack](http://hackage.haskell.org/cgi-bin/hackage-scripts/package/testpack) * [QuickCheck 2](http://hackage.haskell.org/package/QuickCheck) * [HTTP](http://hackage.haskell.org/package/HTTP) - * [hS3](http://hackage.haskell.org/package/hS3) (optional, but recommended) + * [hS3](http://hackage.haskell.org/package/hS3) * [json](http://hackage.haskell.org/package/json) * Shell commands * [git](http://git-scm.com/)