Hello community, here is the log from the commit of package ghc-hakyll for openSUSE:Factory checked in at 2017-06-21 13:55:26 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/ghc-hakyll (Old) and /work/SRC/openSUSE:Factory/.ghc-hakyll.new (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "ghc-hakyll" Wed Jun 21 13:55:26 2017 rev:2 rq:504668 version:4.9.7.0 Changes: -------- --- /work/SRC/openSUSE:Factory/ghc-hakyll/ghc-hakyll.changes 2017-05-17 10:48:47.985709953 +0200 +++ /work/SRC/openSUSE:Factory/.ghc-hakyll.new/ghc-hakyll.changes 2017-06-21 13:55:28.733866007 +0200 @@ -1,0 +2,5 @@ +Mon Jun 12 09:41:39 UTC 2017 - [email protected] + +- Update to version 4.9.7.0. + +------------------------------------------------------------------- Old: ---- hakyll-4.9.5.1.tar.gz New: ---- hakyll-4.9.7.0.tar.gz ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ ghc-hakyll.spec ++++++ --- /var/tmp/diff_new_pack.UUdL7j/_old 2017-06-21 13:55:30.013685477 +0200 +++ /var/tmp/diff_new_pack.UUdL7j/_new 2017-06-21 13:55:30.017684913 +0200 @@ -20,7 +20,7 @@ %global pkg_name hakyll %bcond_with tests Name: ghc-%{pkg_name} -Version: 4.9.5.1 +Version: 4.9.7.0 Release: 0 Summary: A static website compiler library License: BSD-3-Clause ++++++ hakyll-4.9.5.1.tar.gz -> hakyll-4.9.7.0.tar.gz ++++++ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/hakyll-4.9.5.1/CHANGELOG.md new/hakyll-4.9.7.0/CHANGELOG.md --- old/hakyll-4.9.5.1/CHANGELOG.md 2017-02-09 17:52:50.000000000 +0100 +++ new/hakyll-4.9.7.0/CHANGELOG.md 2017-06-10 17:26:50.000000000 +0200 @@ -4,6 +4,21 @@ # Releases +## Hakyll 4.9.7.0 + +- Fix compilation trouble with `Options.Applicative` +- Some small CSS compression improvements (contribution by Nicole Rauch) + +## Hakyll 4.9.6.0 + +- Tighten dependency on `pandoc-citeproc` (contribution by Mikhail Glushenkov) +- Enable using a custom parser for command line arguments (contribution by + Alberto) +- Update examples to semantic HTML (contribution by Elie Génard) +- Better error for `cached` on non-existing file +- Provide an `$allPages$` key when doing pagination +- Preserve file metadata in `copyFileCompiler` (contribution by frederik-h) + ## Hakyll 4.9.5.1 - Bump blaze-html dependency to 0.9 diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/hakyll-4.9.5.1/data/example/css/default.css new/hakyll-4.9.7.0/data/example/css/default.css --- old/hakyll-4.9.5.1/data/example/css/default.css 2017-02-09 17:52:50.000000000 +0100 +++ new/hakyll-4.9.7.0/data/example/css/default.css 2017-06-10 17:26:50.000000000 +0200 @@ -5,25 +5,17 @@ width: 600px; } -div#header { +header { border-bottom: 2px solid black; margin-bottom: 30px; padding: 12px 0px 12px 0px; } -div#logo a { - color: black; - float: left; - font-size: 18px; - font-weight: bold; - text-decoration: none; -} - -div#header #navigation { +nav { text-align: right; } -div#header #navigation a { +nav a { color: black; font-size: 18px; font-weight: bold; @@ -32,7 +24,7 @@ text-transform: uppercase; } -div#footer { +footer { border-top: solid 2px black; color: #555; font-size: 12px; @@ -49,8 +41,16 @@ font-size: 20px; } -div.info { +article .header { color: #555; font-size: 14px; font-style: italic; } + +.logo a { + color: black; + float: left; + font-size: 18px; + font-weight: bold; + text-decoration: none; +} diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/hakyll-4.9.5.1/data/example/templates/default.html new/hakyll-4.9.7.0/data/example/templates/default.html --- old/hakyll-4.9.5.1/data/example/templates/default.html 2017-02-09 17:52:50.000000000 +0100 +++ new/hakyll-4.9.7.0/data/example/templates/default.html 2017-06-10 17:26:50.000000000 +0200 @@ -8,26 +8,26 @@ <link rel="stylesheet" href="/css/default.css" /> </head> <body> - <div id="header"> - <div id="logo"> + <header> + <div class="logo"> <a href="/">My Hakyll Blog</a> </div> - <div id="navigation"> + <nav> <a href="/">Home</a> <a href="/about.html">About</a> <a href="/contact.html">Contact</a> <a href="/archive.html">Archive</a> - </div> - </div> + </nav> + </header> - <div id="content"> + <main role="main"> <h1>$title$</h1> $body$ - </div> + </main> - <div id="footer"> + <footer> Site proudly generated by <a href="http://jaspervdj.be/hakyll">Hakyll</a> - </div> + </footer> </body> </html> diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/hakyll-4.9.5.1/data/example/templates/post.html new/hakyll-4.9.7.0/data/example/templates/post.html --- old/hakyll-4.9.5.1/data/example/templates/post.html 2017-02-09 17:52:50.000000000 +0100 +++ new/hakyll-4.9.7.0/data/example/templates/post.html 2017-06-10 17:26:50.000000000 +0200 @@ -1,8 +1,11 @@ -<div class="info"> - Posted on $date$ - $if(author)$ - by $author$ - $endif$ -</div> - -$body$ +<article> + <section class="header"> + Posted on $date$ + $if(author)$ + by $author$ + $endif$ + </section> + <section> + $body$ + </section> +</article> diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/hakyll-4.9.5.1/hakyll.cabal new/hakyll-4.9.7.0/hakyll.cabal --- old/hakyll-4.9.5.1/hakyll.cabal 2017-02-09 17:52:50.000000000 +0100 +++ new/hakyll-4.9.7.0/hakyll.cabal 2017-06-10 17:26:50.000000000 +0200 @@ -1,5 +1,5 @@ Name: hakyll -Version: 4.9.5.1 +Version: 4.9.7.0 Synopsis: A static website compiler library Description: @@ -169,7 +169,7 @@ network >= 2.6 && < 2.7, network-uri >= 2.6 && < 2.7, pandoc >= 1.14 && < 1.20, - pandoc-citeproc >= 0.4 && < 0.11, + pandoc-citeproc >= 0.4 && < 0.10.5, parsec >= 3.0 && < 3.2, process >= 1.0 && < 1.6, random >= 1.0 && < 1.2, diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/hakyll-4.9.5.1/src/Hakyll/Core/Compiler.hs new/hakyll-4.9.7.0/src/Hakyll/Core/Compiler.hs --- old/hakyll-4.9.5.1/src/Hakyll/Core/Compiler.hs 2017-02-09 17:52:50.000000000 +0100 +++ new/hakyll-4.9.7.0/src/Hakyll/Core/Compiler.hs 2017-06-10 17:26:50.000000000 +0200 @@ -28,7 +28,7 @@ -------------------------------------------------------------------------------- -import Control.Monad (when) +import Control.Monad (when, unless) import Data.Binary (Binary) import Data.ByteString.Lazy (ByteString) import Data.Typeable (Typeable) @@ -149,6 +149,10 @@ id' <- compilerUnderlying <$> compilerAsk store <- compilerStore <$> compilerAsk provider <- compilerProvider <$> compilerAsk + + -- Give a better error message when the resource is not there at all. + unless (resourceExists provider id') $ fail $ itDoesntEvenExist id' + let modified = resourceModified provider id' if modified then do @@ -166,6 +170,11 @@ "Hakyll.Core.Compiler.cached: Cache corrupt! " ++ "Try running: " ++ progName ++ " clean" + itDoesntEvenExist id' = + "Hakyll.Core.Compiler.cached: You are trying to (perhaps " ++ + "indirectly) use `cached` on a non-existing resource: there " ++ + "is no file backing " ++ show id' + -------------------------------------------------------------------------------- unsafeCompiler :: IO a -> Compiler a diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/hakyll-4.9.5.1/src/Hakyll/Core/File.hs new/hakyll-4.9.7.0/src/Hakyll/Core/File.hs --- old/hakyll-4.9.5.1/src/Hakyll/Core/File.hs 2017-02-09 17:52:50.000000000 +0100 +++ new/hakyll-4.9.7.0/src/Hakyll/Core/File.hs 2017-06-10 17:26:50.000000000 +0200 @@ -1,5 +1,6 @@ -------------------------------------------------------------------------------- -- | Exports simple compilers to just copy files +{-# LANGUAGE CPP #-} {-# LANGUAGE DeriveDataTypeable #-} {-# LANGUAGE GeneralizedNewtypeDeriving #-} module Hakyll.Core.File @@ -13,7 +14,12 @@ -------------------------------------------------------------------------------- import Data.Binary (Binary (..)) import Data.Typeable (Typeable) -import System.Directory (copyFile, doesFileExist, +#if MIN_VERSION_directory(1,2,6) +import System.Directory (copyFileWithMetadata) +#else +import System.Directory (copyFile) +#endif +import System.Directory (doesFileExist, renameFile) import System.FilePath ((</>)) import System.Random (randomIO) @@ -38,9 +44,11 @@ -------------------------------------------------------------------------------- instance Writable CopyFile where +#if MIN_VERSION_directory(1,2,6) + write dst (Item _ (CopyFile src)) = copyFileWithMetadata src dst +#else write dst (Item _ (CopyFile src)) = copyFile src dst - - +#endif -------------------------------------------------------------------------------- copyFileCompiler :: Compiler (Item CopyFile) copyFileCompiler = do diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/hakyll-4.9.5.1/src/Hakyll/Main.hs new/hakyll-4.9.7.0/src/Hakyll/Main.hs --- old/hakyll-4.9.5.1/src/Hakyll/Main.hs 2017-02-09 17:52:50.000000000 +0100 +++ new/hakyll-4.9.7.0/src/Hakyll/Main.hs 2017-06-10 17:26:50.000000000 +0200 @@ -1,35 +1,36 @@ -------------------------------------------------------------------------------- -- | Module providing the main hakyll function and command-line argument parsing -{-# LANGUAGE CPP #-} -{-# LANGUAGE DeriveDataTypeable #-} +{-# LANGUAGE CPP #-} + module Hakyll.Main ( hakyll , hakyllWith + , hakyllWithArgs , hakyllWithExitCode ) where -------------------------------------------------------------------------------- -import System.Environment (getProgName) -import System.IO.Unsafe (unsafePerformIO) -import System.Exit (ExitCode(ExitSuccess), exitWith) +import System.Environment (getProgName) +import System.Exit (ExitCode (ExitSuccess), exitWith) +import System.IO.Unsafe (unsafePerformIO) -------------------------------------------------------------------------------- -import Data.Monoid ((<>)) -import Options.Applicative +import Data.Monoid ((<>)) +import qualified Options.Applicative as OA -------------------------------------------------------------------------------- -import qualified Hakyll.Check as Check -import qualified Hakyll.Commands as Commands -import qualified Hakyll.Core.Configuration as Config -import qualified Hakyll.Core.Logger as Logger +import qualified Hakyll.Check as Check +import qualified Hakyll.Commands as Commands +import qualified Hakyll.Core.Configuration as Config +import qualified Hakyll.Core.Logger as Logger import Hakyll.Core.Rules -------------------------------------------------------------------------------- --- | This usualy is the function with which the user runs the hakyll compiler +-- | This usually is the function with which the user runs the hakyll compiler hakyll :: Rules a -> IO () hakyll = hakyllWith Config.defaultConfiguration @@ -39,26 +40,54 @@ hakyllWith :: Config.Configuration -> Rules a -> IO () hakyllWith conf rules = hakyllWithExitCode conf rules >>= exitWith +-------------------------------------------------------------------------------- +-- | A variant of 'hakyll' which returns an 'ExitCode' hakyllWithExitCode :: Config.Configuration -> Rules a -> IO ExitCode -hakyllWithExitCode conf rules = do - args' <- customExecParser (prefs showHelpOnError) (info (helper <*> optionParser conf) (fullDesc <> progDesc (progName ++ " - Static site compiler created with Hakyll"))) - let args'' = optCommand args' - - let verbosity' = if verbosity args' then Logger.Debug else Logger.Message - check' = - if internal_links args'' then Check.InternalLinks else Check.All +hakyllWithExitCode conf rules = do + args <- defaultParser conf + hakyllWithExitCodeAndArgs conf args rules + +-------------------------------------------------------------------------------- +-- | A variant of 'hakyll' which expects a 'Configuration' and command-line +-- 'Options'. This gives freedom to implement your own parsing. +hakyllWithArgs :: Config.Configuration -> Options -> Rules a -> IO () +hakyllWithArgs conf args rules = + hakyllWithExitCodeAndArgs conf args rules >>= exitWith + +-------------------------------------------------------------------------------- +hakyllWithExitCodeAndArgs :: Config.Configuration -> + Options -> Rules a -> IO ExitCode +hakyllWithExitCodeAndArgs conf args rules = do + let args' = optCommand args + verbosity' = if verbosity args then Logger.Debug else Logger.Message + check = + if internal_links args' then Check.InternalLinks else Check.All logger <- Logger.new verbosity' + invokeCommands args' conf check logger rules + +-------------------------------------------------------------------------------- +defaultParser :: Config.Configuration -> IO Options +defaultParser conf = + OA.customExecParser (OA.prefs OA.showHelpOnError) + (OA.info (OA.helper <*> optionParser conf) + (OA.fullDesc <> OA.progDesc + (progName ++ " - Static site compiler created with Hakyll"))) - case args'' of - Build -> Commands.build conf logger rules - Check _ -> Commands.check conf logger check' - Clean -> Commands.clean conf logger >> ok - Deploy -> Commands.deploy conf - Preview p -> Commands.preview conf logger rules p >> ok - Rebuild -> Commands.rebuild conf logger rules - Server _ _ -> Commands.server conf logger (host args'') (port args'') >> ok - Watch _ p s -> Commands.watch conf logger (host args'') p (not s) rules >> ok + +-------------------------------------------------------------------------------- +invokeCommands :: Command -> Config.Configuration -> + Check.Check -> Logger.Logger -> Rules a -> IO ExitCode +invokeCommands args conf check logger rules = + case args of + Build -> Commands.build conf logger rules + Check _ -> Commands.check conf logger check >> ok + Clean -> Commands.clean conf logger >> ok + Deploy -> Commands.deploy conf + Preview p -> Commands.preview conf logger rules p >> ok + Rebuild -> Commands.rebuild conf logger rules + Server _ _ -> Commands.server conf logger (host args) (port args) >> ok + Watch _ p s -> Commands.watch conf logger (host args) p (not s) rules >> ok where ok = return ExitSuccess @@ -79,27 +108,53 @@ | Watch {host :: String, port :: Int, no_server :: Bool } deriving (Show) -optionParser :: Config.Configuration -> Parser Options -optionParser conf = Options <$> verboseParser <*> (commandParser conf) +optionParser :: Config.Configuration -> OA.Parser Options +optionParser conf = Options <$> verboseParser <*> commandParser conf where - verboseParser = switch (long "verbose" <> short 'v' <> help "Run in verbose mode") + verboseParser = OA.switch (OA.long "verbose" <> OA.short 'v' <> OA.help "Run in verbose mode") -commandParser :: Config.Configuration -> Parser Command -commandParser conf = subparser $ foldr ((<>) . produceCommand) mempty commands +commandParser :: Config.Configuration -> OA.Parser Command +commandParser conf = OA.subparser $ foldr ((<>) . produceCommand) mempty commands where - produceCommand (a,b) = command a (info (helper <*> (fst b)) (snd b)) - portParser = option auto (long "port" <> help "Port to listen on" <> value (Config.previewPort conf)) - hostParser = strOption (long "host" <> help "Host to bind on" <> value (Config.previewHost conf)) - commands = [ - ("build",(pure Build,fullDesc <> progDesc "Generate the site")), - ("check",(pure Check <*> switch (long "internal-links" <> help "Check internal links only"), fullDesc <> progDesc "Validate the site output")), - ("clean",(pure Clean,fullDesc <> progDesc "Clean up and remove cache")), - ("deploy",(pure Deploy,fullDesc <> progDesc "Upload/deploy your site")), - ("preview",(pure Preview <*> portParser,fullDesc <> progDesc "[DEPRECATED] Please use the watch command")), - ("rebuild",(pure Rebuild,fullDesc <> progDesc "Clean and build again")), - ("server",(pure Server <*> hostParser <*> portParser,fullDesc <> progDesc "Start a preview server")), - ("watch",(pure Watch <*> hostParser <*> portParser <*> switch (long "no-server" <> help "Disable the built-in web server"),fullDesc <> progDesc "Autocompile on changes and start a preview server. You can watch and recompile without running a server with --no-server.")) + portParser = OA.option OA.auto (OA.long "port" <> OA.help "Port to listen on" <> OA.value (Config.previewPort conf)) + hostParser = OA.strOption (OA.long "host" <> OA.help "Host to bind on" <> OA.value (Config.previewHost conf)) + + produceCommand (c,a,b) = OA.command c (OA.info (OA.helper <*> a) (b)) + + commands = + [ ( "build" + , pure Build + , OA.fullDesc <> OA.progDesc "Generate the site" + ) + , ( "check" + , pure Check <*> OA.switch (OA.long "internal-links" <> OA.help "Check internal links only") + , OA.fullDesc <> OA.progDesc "Validate the site output" + ) + , ( "clean" + , pure Clean + , OA.fullDesc <> OA.progDesc "Clean up and remove cache" + ) + , ( "deploy" + , pure Deploy + , OA.fullDesc <> OA.progDesc "Upload/deploy your site" + ) + , ( "preview" + , pure Preview <*> portParser + , OA.fullDesc <> OA.progDesc "[DEPRECATED] Please use the watch command" + ) + , ( "rebuild" + , pure Rebuild + , OA.fullDesc <> OA.progDesc "Clean and build again" + ) + , ( "server" + , pure Server <*> hostParser <*> portParser + , OA.fullDesc <> OA.progDesc "Start a preview server" + ) + , ( "watch" + , pure Watch <*> hostParser <*> portParser <*> OA.switch (OA.long "no-server" <> OA.help "Disable the built-in web server") + , OA.fullDesc <> OA.progDesc "Autocompile on changes and start a preview server. You can watch and recompile without running a server with --no-server." + ) ] diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/hakyll-4.9.5.1/src/Hakyll/Web/CompressCss.hs new/hakyll-4.9.7.0/src/Hakyll/Web/CompressCss.hs --- old/hakyll-4.9.5.1/src/Hakyll/Web/CompressCss.hs 2017-02-09 17:52:50.000000000 +0100 +++ new/hakyll-4.9.7.0/src/Hakyll/Web/CompressCss.hs 2017-06-10 17:26:50.000000000 +0200 @@ -33,14 +33,15 @@ compressSeparators :: String -> String compressSeparators [] = [] compressSeparators str - | isConstant = head str : retainConstants compressSeparators (head str) (drop 1 str) + | isConstant = head str : retainConstants compressSeparators (head str) (drop 1 str) | stripFirst = compressSeparators (drop 1 str) | stripSecond = compressSeparators (head str : (drop 2 str)) | otherwise = head str : compressSeparators (drop 1 str) where isConstant = or $ map (isOfPrefix str) ["\"", "'"] - stripFirst = or $ map (isOfPrefix str) [" ", " {", " }", " :", ";;", ";}"] - stripSecond = or $ map (isOfPrefix str) ["{ ", "} ", ": ", "; "] + stripFirst = or $ map (isOfPrefix str) $ [";;", ";}"] ++ (map (\c -> " " ++ c) separators) + stripSecond = or $ map (isOfPrefix str) $ map (\c -> c ++ " ") separators + separators = [" ", "{", "}", ":", ";", ",", ">", "+", "!"] -------------------------------------------------------------------------------- -- | Compresses all whitespace. @@ -50,7 +51,7 @@ | isConstant = head str : retainConstants compressWhitespace (head str) (drop 1 str) | replaceOne = compressWhitespace (' ' : (drop 1 str)) | replaceTwo = compressWhitespace (' ' : (drop 2 str)) - | otherwise = head str : compressWhitespace (drop 1 str) + | otherwise = head str : compressWhitespace (drop 1 str) where isConstant = or $ map (isOfPrefix str) ["\"", "'"] replaceOne = or $ map (isOfPrefix str) ["\t", "\n", "\r"] @@ -61,9 +62,9 @@ stripComments :: String -> String stripComments [] = [] stripComments str - | isConstant = head str : retainConstants stripComments (head str) (drop 1 str) + | isConstant = head str : retainConstants stripComments (head str) (drop 1 str) | isPrefixOf "/*" str = stripComments $ eatComments $ drop 2 str - | otherwise = head str : stripComments (drop 1 str) + | otherwise = head str : stripComments (drop 1 str) where isConstant = or $ map (isOfPrefix str) ["\"", "'"] eatComments str' diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/hakyll-4.9.5.1/src/Hakyll/Web/Paginate.hs new/hakyll-4.9.7.0/src/Hakyll/Web/Paginate.hs --- old/hakyll-4.9.5.1/src/Hakyll/Web/Paginate.hs 2017-02-09 17:52:50.000000000 +0100 +++ new/hakyll-4.9.7.0/src/Hakyll/Web/Paginate.hs 2017-06-10 17:26:50.000000000 +0200 @@ -11,7 +11,8 @@ -------------------------------------------------------------------------------- -import Control.Monad (forM_) +import Control.Applicative (empty) +import Control.Monad (forM_, forM) import qualified Data.Map as M import qualified Data.Set as S @@ -93,6 +94,18 @@ -- | A default paginate context which provides the following keys: -- -- +-- * @firstPageNum@ +-- * @firstPageUrl@ +-- * @previousPageNum@ +-- * @previousPageUrl@ +-- * @nextPageNum@ +-- * @nextPageUrl@ +-- * @lastPageNum@ +-- * @lastPageUrl@ +-- * @currentPageNum@ +-- * @currentPageUrl@ +-- * @numPages@ +-- * @allPages@ paginateContext :: Paginate -> PageNumber -> Context a paginateContext pag currentPage = mconcat [ field "firstPageNum" $ \_ -> otherPage 1 >>= num @@ -106,6 +119,20 @@ , field "currentPageNum" $ \i -> thisPage i >>= num , field "currentPageUrl" $ \i -> thisPage i >>= url , constField "numPages" $ show $ paginateNumPages pag + , Context $ \k _ i -> case k of + "allPages" -> do + let ctx = + field "isCurrent" (\n -> if fst (itemBody n) == currentPage then return "true" else empty) `mappend` + field "num" (num . itemBody) `mappend` + field "url" (url . itemBody) + + list <- forM [1 .. lastPage] $ + \n -> if n == currentPage then thisPage i else otherPage n + items <- mapM makeItem list + return $ ListField ctx items + _ -> do + empty + ] where lastPage = paginateNumPages pag diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/hakyll-4.9.5.1/tests/Hakyll/Web/CompressCss/Tests.hs new/hakyll-4.9.7.0/tests/Hakyll/Web/CompressCss/Tests.hs --- old/hakyll-4.9.5.1/tests/Hakyll/Web/CompressCss/Tests.hs 2017-02-09 17:52:50.000000000 +0100 +++ new/hakyll-4.9.7.0/tests/Hakyll/Web/CompressCss/Tests.hs 2017-06-10 17:26:50.000000000 +0200 @@ -37,11 +37,15 @@ -- compress separators , "}" @=? compressCss "; }" - , "{};" @=? compressCss " { } ; " + , ";{};" @=? compressCss " ; { } ; " + , "text," @=? compressCss "text , " + , "a>b" @=? compressCss "a > b" + , "a+b" @=? compressCss "a + b" + , "a!b" @=? compressCss "a ! b" -- compress whitespace even after this curly brace , "}" @=? compressCss "; } " -- but do not compress separators inside of constants - , "\" { } ; \"" @=? compressCss "\" { } ; \"" + , "\" { } ; , \"" @=? compressCss "\" { } ; , \"" -- don't compress separators at the start or end of constants , "\" }\"" @=? compressCss "\" }\"" , "\"{ \"" @=? compressCss "\"{ \"" @@ -51,7 +55,7 @@ -- don't compress whitespace around separators in constants in the middle of a string , "abc '{ '" @=? compressCss "abc '{ '" , "abc \"{ \"" @=? compressCss "abc \"{ \"" - -- compress whitespace after colons + -- compress whitespace around colons , "abc:xyz" @=? compressCss "abc : xyz" -- compress multiple semicolons , ";" @=? compressCss ";;;;;;;"
