From d493a4a22763cc5c72f8dd72b23bf698d12d702a Mon Sep 17 00:00:00 2001 From: geekifan Date: Thu, 5 Jun 2025 15:47:04 +0800 Subject: [PATCH] chore: update configs Moved the hugo.toml configuration from the root directory to config/_default/ to better organize project structure. Updated the markup.toml and params.toml files with additional comments for clarity. --- config/_default/hugo.toml | 25 ++++++++++++++++++++++ config/_default/markup.toml | 1 + config/_default/params.toml | 41 ++++++++++++++++++++++++++++++++++++- hugo.toml | 17 --------------- 4 files changed, 66 insertions(+), 18 deletions(-) create mode 100644 config/_default/hugo.toml delete mode 100644 hugo.toml diff --git a/config/_default/hugo.toml b/config/_default/hugo.toml new file mode 100644 index 0000000..d5e40e5 --- /dev/null +++ b/config/_default/hugo.toml @@ -0,0 +1,25 @@ +# The base URL for the site. +baseURL = 'https://geekifan.github.io/chirpy-starter/' +# The title of the site. +title = 'Chirpy' +# Enable Git info › https://gohugo.io/methods/page/gitinfo/ +enableGitInfo = false +# The default content language. +defaultContentLanguage = "en" +# Whether the default content language is in a subdirectory. +defaultContentLanguageInSubdir = false +# Whether the site has CJK language (Chinese, Japanese, Korean). +hasCJKLanguage = true + +# Pagination settings. +[pagination] + pagerSize = 5 + +# Make sure to include JSON output to support the search functionality. +[outputs] + home = ["HTML", "RSS", "JSON"] + +# Import the theme. +[module] + [[module.imports]] + path = "github.com/geekifan/hugo-theme-chirpy" \ No newline at end of file diff --git a/config/_default/markup.toml b/config/_default/markup.toml index fa790c5..5a8b78b 100644 --- a/config/_default/markup.toml +++ b/config/_default/markup.toml @@ -1,3 +1,4 @@ +# Code highlighting settings. [highlight] anchorLineNos = false codeFences = true diff --git a/config/_default/params.toml b/config/_default/params.toml index 1bd396d..22f0249 100644 --- a/config/_default/params.toml +++ b/config/_default/params.toml @@ -1,8 +1,11 @@ +# boolean type, the global switch for TOC in posts. toc = true +# the avatar on sidebar, should be a relative path to /assets. avatar = "img/commons/avatar.jpg" author = "yifan" [assets] + # Self-hosted static assets, default to false. If true, the assets will be hosted on your own server. self_host = false [social] @@ -27,4 +30,40 @@ author = "yifan" [[social.links]] type = "rss" icon = "fas fa-rss" - noblank = true # will not open in new window \ No newline at end of file + noblank = true # will not open in new window + +[comments] +# Global switch for the post-comment system. [true | false] +enable = false +# The provider options are as follows: [disqus | utterances | giscus] +provider = "" + +# Disqus options +[comments.disqus] +# fill with the Disqus shortname. › https://help.disqus.com/en/articles/1717111-what-s-a-shortname +shortname = "" + +# utterances settings › https://utteranc.es/ +[comments.utterances] +# / +repo = "" +# < url | pathname | title | ...> +issue_term = "" + +# Giscus options › https://giscus.app +[comments.giscus] +# / +repo = "" +repo_id = "" +category = "" +category_id = "" +# optional, default to 'pathname' +mapping = "" +# optional, default to '0' +strict = "" +# optional, default to 'bottom' +input_position = "" +# optional, default to site language +lang = "" +# optional, default to the value of `1` +reactions_enabled = "" \ No newline at end of file diff --git a/hugo.toml b/hugo.toml deleted file mode 100644 index 93b9198..0000000 --- a/hugo.toml +++ /dev/null @@ -1,17 +0,0 @@ -baseURL = 'https://geekifan.github.io/chirpy-starter/' -title = 'Chirpy' -enableGitInfo = false - -defaultContentLanguage = "en" -defaultContentLanguageInSubdir = false -hasCJKLanguage = true - -[pagination] - pagerSize = 5 - -[outputs] - home = ["HTML", "RSS", "JSON"] - -[module] - [[module.imports]] - path = "github.com/geekifan/hugo-theme-chirpy" \ No newline at end of file