diff --git a/web/.gitignore b/web/.gitignore index aebf617..02f82a6 100644 --- a/web/.gitignore +++ b/web/.gitignore @@ -1,2 +1,3 @@ .cabal-sandbox cabal.sandbox.config +dist/ diff --git a/web/LICENSE b/web/LICENSE new file mode 100644 index 0000000..00d2e13 --- /dev/null +++ b/web/LICENSE @@ -0,0 +1,24 @@ +This is free and unencumbered software released into the public domain. + +Anyone is free to copy, modify, publish, use, compile, sell, or +distribute this software, either in source code form or as a compiled +binary, for any purpose, commercial or non-commercial, and by any +means. + +In jurisdictions that recognize copyright laws, the author or authors +of this software dedicate any and all copyright interest in the +software to the public domain. We make this dedication for the benefit +of the public at large and to the detriment of our heirs and +successors. We intend this dedication to be an overt act of +relinquishment in perpetuity of all present and future rights to this +software under copyright law. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, +EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. +IN NO EVENT SHALL THE AUTHORS BE LIABLE FOR ANY CLAIM, DAMAGES OR +OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, +ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR +OTHER DEALINGS IN THE SOFTWARE. + +For more information, please refer to \ No newline at end of file diff --git a/web/src/Main.hs b/web/src/Main.hs new file mode 100644 index 0000000..e31d69d --- /dev/null +++ b/web/src/Main.hs @@ -0,0 +1,13 @@ +{-# LANGUAGE OverloadedStrings #-} +module Main where + +import Data.Monoid +import Web.Spock.Safe + +main :: IO () +main = + runSpock 5000 $ spockT id $ + do get root $ + text "Hello World!" + get ("hello" var) $ \name -> + text ("Hello " <> name <> "!") diff --git a/web/time-wasting-thread-memorial.cabal b/web/time-wasting-thread-memorial.cabal index b1e371e..51ca9d8 100644 --- a/web/time-wasting-thread-memorial.cabal +++ b/web/time-wasting-thread-memorial.cabal @@ -58,10 +58,11 @@ executable time-wasting-thread-memorial -- Other library packages from which modules are imported. build-depends: base >=4.6 && <4.7 + , Spock >=0.7.9 -- Directories containing source files. - -- hs-source-dirs: + hs-source-dirs: src -- Base language which the package is written in. default-language: Haskell2010 - \ No newline at end of file +