Clean up warnings

This commit is contained in:
Michael Snoyman 2016-05-02 15:07:09 +03:00
parent 267f488bca
commit dd0c4e3f4c
2 changed files with 13 additions and 31 deletions

View File

@ -12,26 +12,6 @@ import Yesod.GitRepo (grContent)
import Stackage.Database
import qualified Data.Text as T
executableFor :: SupportedArch -> StackageExecutable
executableFor Win32 = StackageWindowsExecutable
executableFor Win64 = StackageWindowsExecutable
executableFor _ = StackageUnixExecutable
-- TODO: link to s3
executableLink :: SupportedArch -> StackageExecutable -> Text
executableLink arch exe =
"https://s3.amazonaws.com/download.fpcomplete.com/stackage-cli/"
<> toPathPiece arch <> "/" <> toPathPiece exe
downloadCandidates :: [(SupportedArch, StackageExecutable)]
downloadCandidates =
map (\arch -> (arch, executableFor arch))
[minBound .. maxBound]
currentlySupported :: SupportedArch -> Bool
currentlySupported Linux64 = True
currentlySupported _ = False
getDownloadR :: Handler Html
getDownloadR = redirectWith status301 InstallR

View File

@ -2,9 +2,9 @@ module Handler.Sitemap (getSitemapR) where
import Import
import Yesod.Sitemap
import Stackage.Database
--import Stackage.Database
type SitemapFor a = forall m. Monad m => Conduit a m (SitemapUrl (Route App))
--type SitemapFor a = forall m. Monad m => Conduit a m (SitemapUrl (Route App))
type Sitemap = forall m. Monad m => Producer m (SitemapUrl (Route App))
getSitemapR :: Handler TypedContent
@ -56,6 +56,7 @@ ltsSitemap = awaitForever go
slug = show' (ltsMajor lts) <> "." <> show' (ltsMinor lts)
-}
{-
snapshotSitemaps :: SitemapFor Snapshot
snapshotSitemaps = awaitForever go
where
@ -79,18 +80,19 @@ packageMetadataSitemaps = awaitForever go
url' floc = url $ floc $ PackageName $ packageName m
priority :: Double -> Route App -> Sitemap
priority p loc = yield $ SitemapUrl
{ sitemapLoc = loc
, sitemapLastMod = Nothing
, sitemapChangeFreq = Nothing
, sitemapPriority = Just p
}
url :: Route App -> Sitemap
url loc = yield $ SitemapUrl
url loc = yield SitemapUrl
{ sitemapLoc = loc
, sitemapLastMod = Nothing
, sitemapChangeFreq = Nothing
, sitemapPriority = Nothing
}
-}
priority :: Double -> Route App -> Sitemap
priority p loc = yield SitemapUrl
{ sitemapLoc = loc
, sitemapLastMod = Nothing
, sitemapChangeFreq = Nothing
, sitemapPriority = Just p
}