on master help sign in
Cabalized
commit60407d9713a69952293f270be9632f8e7ea3b612 authorMichael Snoyman <michael@snoyman.com> dateTue 14 Sep 2010, 21:00 (16 years ago) parent387ec9a
3 files changed+73
LICENSE+25 Setup.lhs+11 wai-handler-devel.cabal+37
LICENSEnew file+25
@@ -0,0 +1,25 @@
1+The following license covers this documentation, and the source code, except
2+where otherwise indicated.
3+
4+Copyright 2010, Michael Snoyman. All rights reserved.
5+
6+Redistribution and use in source and binary forms, with or without
7+modification, are permitted provided that the following conditions are met:
8+
9+* Redistributions of source code must retain the above copyright notice, this
10+ list of conditions and the following disclaimer.
11+
12+* Redistributions in binary form must reproduce the above copyright notice,
13+ this list of conditions and the following disclaimer in the documentation
14+ and/or other materials provided with the distribution.
15+
16+THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS "AS IS" AND ANY EXPRESS OR
17+IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
18+MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO
19+EVENT SHALL THE COPYRIGHT HOLDERS BE LIABLE FOR ANY DIRECT, INDIRECT,
20+INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
21+NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA,
22+OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
23+LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
24+OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
25+ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
Setup.lhsnew file+11
@@ -0,0 +1,11 @@
1+#!/usr/bin/env runhaskell
2+
3+> module Main where
4+> import Distribution.Simple
5+> import System.Cmd (system)
6+
7+> main :: IO ()
8+> main = defaultMainWithHooks (simpleUserHooks { runTests = runTests' })
9+
10+> runTests' :: a -> b -> c -> d -> IO ()
11+> runTests' _ _ _ _ = system "runhaskell -DTEST runtests.hs" >> return ()
wai-handler-devel.cabalnew file+37
@@ -0,0 +1,37 @@
1+Name: wai-handler-devel
2+Version: 0.0.0
3+Synopsis: WAI server that automatically reloads code after modification.
4+Description: This handler automatically reloads your source code upon any changes. It works by using the hint package, essentially embedding GHC inside the handler. The handler (both the executable and library) takes three arguments: the port to listen on, the module name containing the application function, and the name of the function.
5+ .
6+ One major note: the type of the application is most likely not what you expect. A common case for WAI applications is having a withApplication function, and this library assumes this is the case. Therefore, the type signature of your application function must be:
7+ .
8+ > withYourApp :: (Application -> IO ()) -> IO ()
9+License: BSD3
10+License-file: LICENSE
11+Author: Michael Snoyman
12+Maintainer: michael@snoyman.com
13+Homepage: http://github.com/snoyberg/wai-handler-devel
14+Category: Web
15+Build-Type: Simple
16+Cabal-Version: >=1.6
17+Stability: Stable
18+
19+Source-repository head
20+ type: git
21+ location: git://github.com/snoyberg/wai-handler-devel.git
22+
23+Library
24+ Build-Depends: base >= 3 && < 5,
25+ wai >= 0.2.1 && < 0.3,
26+ directory >= 1.0 && < 1.1,
27+ sendfile >= 0.6 && < 0.8,
28+ network >= 2.2 && < 2.3,
29+ bytestring >= 0.9 && < 0.10,
30+ hint >= 0.3.2.3 && < 0.4
31+ Exposed-modules: Network.Wai.Handler.DevelServer
32+ ghc-options: -Wall
33+
34+Executable wai-handler-devel
35+ Build-Depends: cmdargs >= 0.4 && < 0.5
36+ ghc-options: -Wall -O2 -threaded
37+ main-is: wai-handler-devel.hs