webapp: Display some additional information about a repository on its edit page.

This commit is contained in:
Joey Hess 2013-04-25 16:42:17 -04:00
parent 3e396a3b89
commit e3ea36174b
7 changed files with 73 additions and 16 deletions

View file

@ -5,7 +5,7 @@
- Licensed under the GNU GPL version 3 or higher.
-}
module Remote.S3 (remote, iaHost, isIAHost) where
module Remote.S3 (remote, iaHost, isIA, isIAHost, iaItemUrl) where
import Network.AWS.AWSConnection
import Network.AWS.S3Object
@ -283,3 +283,6 @@ isIA c = maybe False isIAHost (M.lookup "host" c)
isIAHost :: HostName -> Bool
isIAHost h = ".archive.org" `isSuffixOf` map toLower h
iaItemUrl :: String -> String
iaItemUrl bucket = "http://archive.org/details/" ++ bucket