yesod 0.9.1 → 0.9.1.1
raw patch · 7 files changed
+36/−22 lines, 7 filesdep ~yesod-corenew-uploaderPVP ok
version bump matches the API change (PVP)
Dependency ranges changed: yesod-core
API changes (from Hackage documentation)
Files
- Build.hs +3/−3
- scaffold/Foundation.hs.cg +2/−2
- scaffold/Settings.hs.cg +10/−3
- scaffold/hamlet/boilerplate-layout.hamlet.cg +7/−7
- scaffold/tiny/Foundation.hs.cg +2/−2
- scaffold/tiny/Settings.hs.cg +10/−3
- yesod.cabal +2/−2
Build.hs view
@@ -75,8 +75,8 @@ contents <- getDirectoryContents path fmap concat $ mapM go contents where- go ('.':_) = return []- go "dist" = return []+ go ('.':_) = return []+ go ('d':"ist") = return [] go x = do let y = path ++ '/' : x d <- doesDirectoryExist y@@ -141,7 +141,7 @@ getFolderContents fp = do cs <- getDirectoryContents fp let notHidden ('.':_) = False- notHidden "tmp" = False+ notHidden ('t':"mp") = False notHidden _ = True fmap concat $ forM (filter notHidden cs) $ \c -> do let f = fp ++ '/' : c
scaffold/Foundation.hs.cg view
@@ -84,8 +84,8 @@ mmsg <- getMessage pc <- widgetToPageContent $ do widget- addCassius $(Settings.cassiusFile "default-layout")- hamletToRepHtml $(Settings.hamletFile "default-layout")+ addCassius $(cassiusFile "default-layout")+ hamletToRepHtml $(hamletFile "default-layout") -- This is done to provide an optimization for serving static files from -- a separate domain. Please see the staticRoot setting in Settings.hs
scaffold/Settings.hs.cg view
@@ -85,15 +85,22 @@ loadConfig env = do allSettings <- (join $ YAML.decodeFile ("config/settings.yml" :: String)) >>= fromMapping settings <- lookupMapping (show env) allSettings- portS <- lookupScalar "port" settings hostS <- lookupScalar "host" settings+ port <- fmap read $ lookupScalar "port" settings connectionPoolSizeS <- lookupScalar "connectionPoolSize" settings return $ AppConfig { appEnv = env- , appPort = read portS- , appRoot = pack (hostS ++ ":" ++ portS)+ , appPort = port+ , appRoot = pack $ hostS ++ addPort port , connectionPoolSize = read connectionPoolSizeS }+ where+ addPort :: Int -> String+#ifdef PRODUCTION+ addPort _ = ""+#else+ addPort p = ":" ++ (show p)+#endif -- Static setting below. Changing these requires a recompile
scaffold/hamlet/boilerplate-layout.hamlet.cg view
@@ -1,10 +1,10 @@-\<!doctype html>M-\<!--[if lt IE 7 ]> <html lang="en" class="no-js ie6"> <![endif]-->^M-\<!--[if IE 7 ]> <html lang="en" class="no-js ie7"> <![endif]-->^M-\<!--[if IE 8 ]> <html lang="en" class="no-js ie8"> <![endif]-->^M-\<!--[if IE 9 ]> <html lang="en" class="no-js ie9"> <![endif]-->^M+\<!doctype html> +\<!--[if lt IE 7 ]> <html lang="en" class="no-js ie6"> <![endif]--> +\<!--[if IE 7 ]> <html lang="en" class="no-js ie7"> <![endif]--> +\<!--[if IE 8 ]> <html lang="en" class="no-js ie8"> <![endif]--> +\<!--[if IE 9 ]> <html lang="en" class="no-js ie9"> <![endif]--> \<!--[if (gt IE 9)|!(IE)]><!-->-<html lang="en" class="no-js"><!--<![endif]-->^M+<html lang="en" class="no-js"><!--<![endif]--> <head> <meta charset="UTF-8"> <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">@@ -20,7 +20,7 @@ <!--[if lt IE 9]> <script src="http://html5shiv.googlecode.com/svn/trunk/html5.js"></script>- <![endif]-->^M+ <![endif]--> <script> document.documentElement.className = document.documentElement.className.replace(/\bno-js\b/,'js');
scaffold/tiny/Foundation.hs.cg view
@@ -70,8 +70,8 @@ mmsg <- getMessage pc <- widgetToPageContent $ do widget- addCassius $(Settings.cassiusFile "default-layout")- hamletToRepHtml $(Settings.hamletFile "default-layout")+ addCassius $(cassiusFile "default-layout")+ hamletToRepHtml $(hamletFile "default-layout") -- This is done to provide an optimization for serving static files from -- a separate domain. Please see the staticroot setting in Settings.hs
scaffold/tiny/Settings.hs.cg view
@@ -67,13 +67,20 @@ loadConfig env = do allSettings <- (join $ YAML.decodeFile ("config/settings.yml" :: String)) >>= fromMapping settings <- lookupMapping (show env) allSettings- portS <- lookupScalar "port" settings hostS <- lookupScalar "host" settings+ port <- fmap read $ lookupScalar "port" settings return $ AppConfig { appEnv = env- , appPort = read portS- , appRoot = pack (hostS ++ ":" ++ portS)+ , appPort = port+ , appRoot = pack $ hostS ++ addPort port }+ where+ addPort :: Int -> String+#ifdef PRODUCTION+ addPort _ = ""+#else+ addPort p = ":" ++ (show p)+#endif -- | The location of static files on your system. This is a file system -- path. The default value works properly with your scaffolded site.
yesod.cabal view
@@ -1,5 +1,5 @@ name: yesod-version: 0.9.1+version: 0.9.1.1 license: BSD3 license-file: LICENSE author: Michael Snoyman <michael@snoyman.com>@@ -62,7 +62,7 @@ cpp-options: -DGHC7 else build-depends: base >= 4 && < 4.3- build-depends: yesod-core >= 0.9 && < 0.10+ build-depends: yesod-core >= 0.9.1.1 && < 0.10 , yesod-auth >= 0.7 && < 0.8 , yesod-json >= 0.2 && < 0.3 , yesod-persistent >= 0.2 && < 0.3