From 511b1c21e9e7bd40cf450a8b898e2bf9f4ebbfab Mon Sep 17 00:00:00 2001 From: Michael Snoyman Date: Fri, 1 May 2015 11:39:24 +0300 Subject: [PATCH] Added /download/snapshots.json --- Handler/Download.hs | 4 ++++ config/routes | 1 + 2 files changed, 5 insertions(+) diff --git a/Handler/Download.hs b/Handler/Download.hs index e264fe6..3098cc6 100644 --- a/Handler/Download.hs +++ b/Handler/Download.hs @@ -1,5 +1,6 @@ module Handler.Download ( getDownloadR + , getDownloadSnapshotsJsonR , getDownloadLtsSnapshotsJsonR , getGhcMajorVersionR , getDownloadGhcLinksR @@ -47,6 +48,9 @@ dropOldMinors (l@(Lts x _ _):rest) = where sameMinor (Lts y _ _) = x == y +getDownloadSnapshotsJsonR :: Handler Value +getDownloadSnapshotsJsonR = getDownloadLtsSnapshotsJsonR + getDownloadLtsSnapshotsJsonR :: Handler Value getDownloadLtsSnapshotsJsonR = do (mlatestNightly, ltses) <- runDB $ (,) diff --git a/config/routes b/config/routes index 64bb56f..b6aa470 100644 --- a/config/routes +++ b/config/routes @@ -60,5 +60,6 @@ /package-counts PackageCountsR GET /download DownloadR GET +/download/snapshots.json DownloadSnapshotsJsonR GET /download/lts-snapshots.json DownloadLtsSnapshotsJsonR GET /download/#SupportedArch/#Text DownloadGhcLinksR GET