mirror of
http://101.35.51.105:3000/congyu/work_with_codex.git
synced 2026-04-27 22:30:50 +08:00
remove fancy routes
This commit is contained in:
+1
-11
@@ -9,16 +9,6 @@ import Hakyll
|
||||
import System.FilePath
|
||||
import Text.Pandoc
|
||||
|
||||
--------------------------------------------------------------------------------
|
||||
-- https://www.rohanjain.in/hakyll-clean-urls/
|
||||
cleanRoute :: Routes
|
||||
cleanRoute = customRoute createIndexRoute
|
||||
where
|
||||
createIndexRoute ident = takeDirectory p </> takeBaseName p </> "index.html"
|
||||
where
|
||||
p = toFilePath ident
|
||||
--------------------------------------------------------------------------------
|
||||
|
||||
config :: Configuration
|
||||
config =
|
||||
defaultConfiguration
|
||||
@@ -52,7 +42,7 @@ main = hakyllWith config $ do
|
||||
compile compressCssCompiler
|
||||
|
||||
match "notes/*" $ do
|
||||
route cleanRoute
|
||||
route $ setExtension "html"
|
||||
compile $ do
|
||||
tocCtx <- getTocCtx defaultContext
|
||||
chaoDocCompiler
|
||||
|
||||
Reference in New Issue
Block a user