From b5208b3f4b6d28b77a1cd2c9cf805c1c339a0a19 Mon Sep 17 00:00:00 2001 From: Cell <1024@lruihao.cn> Date: Fri, 1 Dec 2023 17:20:12 +0800 Subject: [PATCH] :wrench: Chore: update default hugo.toml --- hugo.toml | 107 ++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 107 insertions(+) diff --git a/hugo.toml b/hugo.toml index 43abd85e..a97c1665 100644 --- a/hugo.toml +++ b/hugo.toml @@ -884,3 +884,110 @@ enableEmoji = true [module.hugoVersion] extended = true min = "0.110.0" + +# ------------------------------------------------------------------------------------- +# Markup related configuration in Hugo +# See: https://gohugo.io/getting-started/configuration-markup/ +# ------------------------------------------------------------------------------------- + +[markup] + # Syntax Highlighting (https://gohugo.io/content-management/syntax-highlighting) + [markup.highlight] + ########## necessary configurations ########## + # https://github.com/hugo-fixit/FixIt/issues/43 + codeFences = true + lineNos = true + lineNumbersInTable = true + noClasses = false + ########## necessary configurations ########## + guessSyntax = true + # Goldmark is from Hugo 0.60 the default library used for Markdown + [markup.goldmark] + [markup.goldmark.extensions] + definitionList = true + footnote = true + linkify = true + strikethrough = true + table = true + taskList = true + typographer = true + [markup.goldmark.renderer] + # whether to use HTML tags directly in the document + unsafe = true + # Table Of Contents settings + [markup.tableOfContents] + startLevel = 2 + endLevel = 6 + +# ------------------------------------------------------------------------------------- +# Sitemap Configuration +# See: https://gohugo.io/templates/sitemap-template/#configuration +# ------------------------------------------------------------------------------------- + +[sitemap] + changefreq = "weekly" + filename = "sitemap.xml" + priority = 0.5 + +# ------------------------------------------------------------------------------------- +# Permalinks Configuration +# See: https://gohugo.io/content-management/urls/#permalinks +# ------------------------------------------------------------------------------------- + +[Permalinks] + # posts = ":year/:month/:filename" + posts = "posts/:slugorfilename" + +# ------------------------------------------------------------------------------------- +# Privacy Configuration +# See: https://gohugo.io/about/hugo-and-gdpr/ +# ------------------------------------------------------------------------------------- + +[privacy] + [privacy.twitter] + enableDNT = true + [privacy.youtube] + privacyEnhanced = true + +# ------------------------------------------------------------------------------------- +# Media Types +# See: https://gohugo.io/templates/output-formats/#media-types +# ------------------------------------------------------------------------------------- + +[mediaTypes] + # Options to make output .md files + [mediaTypes."text/markdown"] + suffixes = ["md"] + # Options to make output .txt files + [mediaTypes."text/plain"] + suffixes = ["txt"] + +# ------------------------------------------------------------------------------------- +# Output Format Definitions +# See: https://gohugo.io/templates/output-formats/#output-format-definitions +# ------------------------------------------------------------------------------------- + +[outputFormats] + # Options to make output .md files + [outputFormats.MarkDown] + mediaType = "text/markdown" + isPlainText = true + isHTML = false + # FixIt 0.2.15 | NEW Options to make output baidu_urls.txt file + [outputFormats.BaiduUrls] + baseName = "baidu_urls" + mediaType = "text/plain" + isPlainText = true + isHTML = false + +# ------------------------------------------------------------------------------------- +# Customizing Output Formats +# See: https://gohugo.io/templates/output-formats/#customizing-output-formats +# ------------------------------------------------------------------------------------- + +[outputs] + home = ["HTML", "RSS", "JSON", "BaiduUrls"] + page = ["HTML", "MarkDown"] + section = ["HTML", "RSS"] + taxonomy = ["HTML"] + term = ["HTML", "RSS"]