need to figure out rules for index.html and index.xml

This commit is contained in:
Pagwin 2024-07-22 00:32:58 -04:00
parent 9485e9af58
commit 2dc9cb3dc6
No known key found for this signature in database
GPG key ID: 81137023740CA260
2 changed files with 3 additions and 2 deletions

View file

@ -1,5 +1,6 @@
-- pulling heavily from https://abhinavsarkar.net/posts/static-site-generator-using-shake/ -- pulling heavily from https://abhinavsarkar.net/posts/static-site-generator-using-shake/
-- docs: -- docs:
-- https://hackage.haskell.org/package/shake-0.19.8/docs/doc-index-All.html
-- https://hackage.haskell.org/package/pandoc-3.2.1/docs/doc-index-All.html -- https://hackage.haskell.org/package/pandoc-3.2.1/docs/doc-index-All.html
-- https://hackage.haskell.org/package/mustache-2.4.2/docs/doc-index.html -- https://hackage.haskell.org/package/mustache-2.4.2/docs/doc-index.html
-- --
@ -31,7 +32,7 @@ main = Shake.shakeArgs Shake.shakeOptions $ do
"build" ~> buildSite "build" ~> buildSite
Shake.withTargetDocs "Clean the built site" $ Shake.withTargetDocs "Clean the built site" $
"clean" ~> Shake.removeFilesAfter outputDir ["//*"] "clean" ~> Shake.removeFilesAfter outputDir ["//*"]
Shake.withoutTargets buildRules
buildSite :: Action () buildSite :: Action ()
buildSite = do buildSite = do

View file

@ -18,7 +18,7 @@ indexHtmlOutputPath srcPath =
indexHtmlSourcePath :: FilePath -> FilePath indexHtmlSourcePath :: FilePath -> FilePath
indexHtmlSourcePath = indexHtmlSourcePath =
Shake.dropDirectory1 Shake.dropDirectory1
. (<.> "typ") . (<.> "typ")
. Shake.dropTrailingPathSeparator . Shake.dropTrailingPathSeparator
. Shake.dropFileName . Shake.dropFileName