This commit is contained in:
Etienne Werly 2023-07-18 19:06:45 +02:00
parent a9c51756fc
commit 7107b0e99f
3 changed files with 4 additions and 2 deletions

View file

@ -7,6 +7,7 @@ import Components
import Core.Render ( )
import Hakyll
import Text.Pandoc.Options
myPandocReaderOptions :: ReaderOptions
myPandocReaderOptions = def
{ readerExtensions = disableExtension Ext_tex_math_dollars pandocExtensions

View file

@ -1,6 +1,7 @@
module Core.Parsers where
import Components
import Control.Monad ( join )
import Data.Functor
import Data.Void
import Routes
@ -11,7 +12,7 @@ import Utils.FileTree
type Parser = Parsec Void String
parseFilePath :: Parser FilePath
parseFilePath = some $ alphaNumChar <|> oneOf ("/-_. " :: String)
parseFilePath = some $ alphaNumChar <|> oneOf ("/-_., " :: String)
parseWord :: Parser (Component ())
parseWord = fmap return $ some (alphaNumChar <|> punctuationChar) *> space

View file

@ -7,7 +7,7 @@ import Hakyll
import Routes
patrn :: Route -> Pattern
patrn = fromGlob . tail . path
patrn = fromGlob . local
local :: Route -> FilePath
local = drop 1 . path