diff --git a/LICENSE b/LICENSE
new file mode 100644
--- /dev/null
+++ b/LICENSE
@@ -0,0 +1,30 @@
+Copyright (c) 2008 Don Stewart
+
+All rights reserved.
+
+Redistribution and use in source and binary forms, with or without
+modification, are permitted provided that the following conditions
+are met:
+
+1. Redistributions of source code must retain the above copyright
+   notice, this list of conditions and the following disclaimer.
+
+2. Redistributions in binary form must reproduce the above copyright
+   notice, this list of conditions and the following disclaimer in the
+   documentation and/or other materials provided with the distribution.
+
+3. Neither the name of the author nor the names of his contributors
+   may be used to endorse or promote products derived from this software
+   without specific prior written permission.
+
+THIS SOFTWARE IS PROVIDED BY THE AUTHORS ``AS IS'' AND ANY EXPRESS OR
+IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+DISCLAIMED.  IN NO EVENT SHALL THE AUTHORS OR CONTRIBUTORS BE LIABLE FOR
+ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
+DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
+OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
+HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
+STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN
+ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
+POSSIBILITY OF SUCH DAMAGE.
diff --git a/Main.hs b/Main.hs
new file mode 100644
--- /dev/null
+++ b/Main.hs
@@ -0,0 +1,51 @@
+--------------------------------------------------------------------
+-- |
+-- Module    : Generate sparkline graphs of hackage uploads
+-- Copyright : (c) Don Stewart 2008
+-- License   : BSD3
+--
+-- Maintainer: Don Stewart <dons@galois.com>
+-- Stability : provisional
+-- Portability:
+--
+--------------------------------------------------------------------
+
+import Data.List
+import Data.Maybe
+import Graphics.Rendering.HSparklines
+import System.Locale
+import System.Time
+import System.Time.Parse
+import System.Directory
+import System.FilePath
+import Text.HTML.Download
+
+url = "http://hackage.haskell.org/packages/archive/log"
+
+png1 = "hackage-monthly.png"
+png2 = "hackage-daily.png"
+
+main :: IO ()
+main = do
+    pwd <- getCurrentDirectory
+    src <- openURL url
+    let dates    = catMaybes . sort . map parse . lines $ src
+
+    -- uploads per year
+    let  permonth = groupBy month dates
+    graph <- make ((barSpark {bgColor = rgb 0xee 0xee 0xee}) ) (map genericLength permonth)
+    savePngFile png1 graph
+    putStrLn $ "Wrote: " ++ pwd </> png1
+
+    -- print uploads this month
+    let today = last dates
+        thismonth = groupBy day . filter (month today) $ dates
+    graph <- make ((barSpark {bgColor = rgb 0xee 0xee 0xee
+                             , limits = (0,20)} )) (map genericLength thismonth)
+    savePngFile png2 graph
+    putStrLn $ "Wrote: " ++ pwd </> png2
+
+  where
+    parse = parseCalendarTime defaultTimeLocale "%c"
+    month a b = ctYear a == ctYear b && ctMonth a == ctMonth b
+    day   a b = month a b && ctDay a == ctDay b
diff --git a/Setup.lhs b/Setup.lhs
new file mode 100644
--- /dev/null
+++ b/Setup.lhs
@@ -0,0 +1,3 @@
+#!/usr/bin/env runhaskell
+> import Distribution.Simple
+> main = defaultMain
diff --git a/examples/hackage-daily.png b/examples/hackage-daily.png
new file mode 100644
Binary files /dev/null and b/examples/hackage-daily.png differ
diff --git a/examples/hackage-monthly.png b/examples/hackage-monthly.png
new file mode 100644
Binary files /dev/null and b/examples/hackage-monthly.png differ
diff --git a/hackage-sparks.cabal b/hackage-sparks.cabal
new file mode 100644
--- /dev/null
+++ b/hackage-sparks.cabal
@@ -0,0 +1,25 @@
+name:                hackage-sparks
+version:             0.1
+homepage:            http://code.haskell.org/~dons/code/hackage-sparks
+license:             BSD3
+license-file:        LICENSE
+author:              Don Stewart
+maintainer:          dons@galois.com
+category:            Graphics
+synopsis:            Generate sparkline graphs of hackage statistics
+description:         Generate sparkline graphs of hackage statistics
+cabal-version:       >= 1.2
+build-type:          Simple
+
+flag small_base
+  description: Choose the new smaller, split-up base package.
+
+executable hackagesparks
+    main-is:         Main.hs
+
+    if flag(small_base) 
+        build-depends:   base >= 3, old-locale, old-time, directory
+    else
+        build-depends:   base <  3
+    build-depends:   hsparklines, tagsoup, parsedate, filepath
+
