config.toml 8.2 KB
Newer Older
D
Dillon 已提交
1
baseURL = "https://example.com/"
D
Dillon 已提交
2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22
# 网站语言
languageCode = "zh"
# [en, zh, ...] 设定主题的国际化
defaultContentLanguage = "zh"
# 网站标题
title = "LoveIt 主题"
# 主题
theme = "LoveIt"
# 是否使用 git 信息来生成文章的上次修改时间
enableGitInfo = false
# 是否包括中日韩文字
hasCJKLanguage = true
# 默认每页列表显示的文章数目
paginate = 12
# 是否使用 emoji 代码
enableEmoji = true
# 是否使用 robots.txt
enableRobotsTXT = true
# [UA-XXXXXXXX-X] 谷歌分析代号
googleAnalytics = ""
# 版权描述,仅仅用于 SEO
23
copyright = "This work is licensed under a Creative Commons Attribution-NonCommercial 4.0 International License."
D
Dillon 已提交
24 25
# 日期格式
dateFormatToUse = "2006-01-02"
26

D
Dillon 已提交
27 28 29 30 31 32 33 34 35 36 37 38 39 40
# Hugo 解析文档的配置
[markup]
  # 代码高亮设置 (https://gohugo.io/content-management/syntax-highlighting)
  [markup.highlight]
    codeFences = true
    guessSyntax = true
    lineNoStart = 1
    lineNos = true
    lineNumbersInTable = true
    noClasses = false
    style = "monokai"
    tabWidth = 4
  # Goldmark 是 Hugo 0.60 以来的默认 Markdown 解析库
  [markup.goldmark]
41 42 43 44 45 46 47 48
    [markup.goldmark.extensions]
      definitionList = true
      footnote = true
      linkify = true
      strikethrough = true
      table = true
      taskList = true
      typographer = true
D
Dillon 已提交
49 50 51 52 53 54 55
    [markup.goldmark.renderer]
      # 是否在文档中直接使用 HTML 标签
      unsafe = true
  # 目录设置
  [markup.tableOfContents]
    startLevel = 2
    endLevel = 6
56

D
Dillon 已提交
57 58 59 60
# 作者信息
[author]
  name = "xxxx"
  link = ""
61

D
Dillon 已提交
62 63
# 网站地图信息
[sitemap]
64 65 66 67
  changefreq = "weekly"
  filename = "sitemap.xml"
  priority = 0.5

D
Dillon 已提交
68 69
# Permalinks 信息 (https://gohugo.io/content-management/urls/#permalinks)
[Permalinks]
70
  posts = ":year/:month/:filename"
71

D
Dillon 已提交
72 73
# 菜单信息
[menu]
74 75 76
  [[menu.main]]
    identifier = "posts"
    name = "文章"
77
    url = "posts"
78 79 80 81 82
    weight = 1

  [[menu.main]]
    identifier = "tags"
    name = "标签"
83
    url = "tags"
84 85 86 87
    weight = 2

  [[menu.main]]
    identifier = "categories"
D
Dillon ZENG 已提交
88
    name = "分类"
89
    url = "categories"
90 91 92 93 94
    weight = 3

  [[menu.main]]
    identifier = "about"
    name = "关于"
95
    url = "about"
96 97 98 99
    weight = 4

  [[menu.main]]
    identifier = "en"
D
Dillon 已提交
100 101 102
    pre = '<i class="fas fa-language fa-fw"></i>'
    name = ""
    title = "English"
103 104 105 106
    url = "https://hugo-loveit-en.netlify.com"
    weight = 5

[params]
D
Dillon 已提交
107 108 109 110 111 112
  # LoveIt 主题版本
  version = "0.1.X"
  # 网站描述
  description = "关于 LoveIt 主题"
  # 网站关键词
  keywords = ["Theme", "Hugo"]
113

D
Dillon 已提交
114 115 116 117 118 119 120 121 122
  # 主页信息设置
  ## [post, other] 主页模式
  home_mode = "post"
  ## 主页在 post 模式下每页 post 显示数量
  home_paginate = 6
  ## 主页显示头像的 URL
  avatar = "images/avatar.png"
  ## 主页显示的网站副标题
  subtitle = "一个简洁、优雅且高效的 Hugo 主题"
123

D
Dillon 已提交
124 125
  # 在文章页面是否使用分享功能
  socialShare = true
126

D
Dillon 已提交
127 128
  # 页面底部版权信息设置
  ## 网站创立年份
D
Dillon 已提交
129
  since = 2019
D
Dillon 已提交
130 131 132
  ## ICP 备案信息,仅在中国使用 (允许使用 HTML 格式)
  icp = ""
  ## 许可协议信息 (允许使用 HTML 格式)
133 134
  license= '<a rel="license external nofollow noopener noreffer" href="https://creativecommons.org/licenses/by-nc/4.0/" target="_blank">CC BY-NC 4.0</a>'

D
Dillon 已提交
135 136 137
  # 用于生成文章上次修改时间的公共 git 仓库路径,仅在 enableGitInfo 设为 true 时有效
  gitRepo = ""

138 139 140 141 142 143 144 145 146 147 148 149
  # 数学公式 (KaTeX https://katex.org/)
  [params.math]
    enable = true
    block_left_delimiter = ""
    block_right_delimiter = ""
    inline_left_delimiter = "$"
    inline_right_delimiter = "$"
    # KaTeX 插件 copy_tex
    copy_tex = true
    # KaTeX 插件 mhchem
    mhchem = true

D
Dillon 已提交
150 151
  # 是否在文章页面显示原始 Markdown 文档链接
  linkToMarkdown = true
152

D
Dillon 已提交
153
  # 网站验证代码,用于 Google/Bing/Yandex/Pinterest/Baidu
154 155 156 157 158 159
  google_verification = ""
  bing_verification = ""
  yandex_verification = ""
  pinterest_verification = ""
  baidu_verification = ""

D
Dillon 已提交
160 161 162 163
  # CSS 和 JS 文件的 CDN 设置
  [params.cdn]
    ## 例如 '<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/@fortawesome/fontawesome-free@5.10.1/css/all.min.css" integrity="sha256-fdcFNFiBMrNfWL6OcAGQz6jDgNTRxnrLEd4vJYFWScE=" crossorigin="anonymous">'
    fontawesome_free_css = ''
164 165 166 167 168 169 170 171 172 173
    animate_css = ''
    gitalk_css = ''
    gitalk_js = ''
    valine_js = ''
    jquery_js = ''
    lazysizes_js = ''
    smooth_scroll_js = ''
    katex_css = ''
    katex_js = ''
    katex_auto_render_js = ''
174 175 176
    katex_copy_tex_css = ''
    katex_copy_tex_js = ''
    katex_mhchem_js = ''
177
    mermaid_js = ''
178 179
    echarts_js = ''
    echarts_macarons_js = ''
180 181 182 183 184 185
    typeit_js = ''
    jquery_countdown_js = ''
    aplayer_css = ''
    aplayer_js = ''
    meting_js = ''

D
Dillon 已提交
186 187
  # Gravatar 信息,用于优先在主页显示的头像
  [params.gravatar]
188 189
    email = ""

D
Dillon 已提交
190 191
  # 主页的社交信息设置
  [params.social]
192 193 194 195
    GitHub = "xxxx"
    Linkedin = "xxxx"
    Twitter = "xxxx"
    #Instagram = "xxxx"
D
Dillon 已提交
196
    Email = "xxxx@outlook.com"
197 198 199 200 201 202 203 204 205 206 207 208 209
    Facebook = "xxxx"
    Telegram = "xxxx"
    #Medium = "xxxx"
    #Gitlab = "xxxx"
    #Youtubelegacy = "xxxx"
    #Youtubecustom = "xxxx"
    #Youtubechannel = "xxxx"
    #Tumblr ="xxxx"
    #Quora = "xxxx"
    #Keybase = "xxxx"
    #Pinterest = "xxxx"
    #Reddit = "xxxx"
    #Codepen = "xxxx"
D
Dillon 已提交
210
    #FreeCodeCamp = "xxxx"
211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249
    #Bitbucket = "xxxx"
    #Stackoverflow = "xxxx"
    #Weibo = "xxxx"
    #Odnoklassniki = "xxxx"
    #VKontakte = "xxxx"
    #Flickr = "xxxx"
    #Xing = "xxxx"
    #Snapchat = "xxxx"
    #Soundcloud = "xxxx"
    #Spotify = "xxxx"
    #Bandcamp = "xxxx"
    #Paypal = "xxxx"
    #Fivehundredpx = "xxxx"
    #Mix = "xxxx"
    #Goodreads = "xxxx"
    #Lastfm = "xxxx"
    #Foursquare = "xxxx"
    #Hackernews = "xxxx"
    #Kickstarter = "xxxx"
    #Patreon = "xxxx"
    #Steam = "xxxx"
    #Twitch = "xxxx"
    #Strava = "xxxx"
    #Skype = "xxxx"
    #Whatsapp = "xxxx"
    #Zhihu = "xxxx"
    #Douban = "xxxx"
    #Angellist = "xxxx"
    #Slidershare = "xxxx"
    #Jsfiddle = "xxxx"
    #Deviantart = "xxxx"
    #Behance = "xxxx"
    #Dribble = "xxxx"
    #Wordpress = "xxxx"
    #Vine = "xxxx"
    #Googlescholar = "xxxx"
    #Researchgate = "xxxx"
    #Mastodon = "xxxx"
    #Thingiverse = "xxxx"
P
Programazing 已提交
250
    #Devto = "xxxx"
251

D
Dillon 已提交
252 253
  # 文章页面的分享信息设置
  [params.share]
254 255 256 257 258 259 260 261 262 263 264 265
    enable = true
    Twitter = true
    Facebook = true
    Reddit = true
    #Linkedin = true
    #Pinterest = true
    #HackerNews = true
    #Mix = true
    #Tumblr = true
    #VKontakte = true
    #Weibo = true

D
Dillon 已提交
266 267 268
  # 出版者信息,仅用于 SEO
  [params.publisher]
    name = "xxxx"
269
    [params.publisher.logo]
270
      url = "logo.png"
271 272 273
      width = 127
      height = 40

D
Dillon 已提交
274 275
  # 网站图标信息,仅用于 SEO
  [params.logo]
276
    url = "logo.png"
277 278 279
    width = 127
    height = 40

D
Dillon 已提交
280 281
  #  网站图标信息,仅用于 SEO
  [params.image]
282
    url = "cover.png"
283 284 285
    width = 800
    height = 600

D
Dillon 已提交
286 287 288 289 290 291 292
  # Disqus 评论系统设置 (https://disqus.com/)
  [params.disqus]
    # Disqus 的用户名,用来在文章中启用 Disqus 评论系统
    shortname = "dillonzq"

  # Gittalk 评论系统设置 (https://github.com/gitalk/gitalk)
  [params.gitalk]
293 294 295 296 297
    owner = ""
    repo = ""
    clientId = ""
    clientSecret = ""

D
Dillon 已提交
298 299
  # Valine 评论系统设置 (https://github.com/xCss/Valine)
  [params.valine]
300 301 302 303 304 305
    enable = false
    appId = ""
    appKey = ""
    notify = false
    verify = true
    avatar = "mp"
D
Dillon 已提交
306
    placeholder = "你的评论 ..."
307 308 309
    visitor = true
    recordIP = true

D
Dillon 已提交
310 311 312 313 314 315 316 317 318 319
  # Facebook 评论系统设置 (https://developers.facebook.com/docs/plugins/comments)
  [params.facebook]
    enable = false
    width = "100%"
    numPosts = 10
    appId = ""
    languageCode = "en_US"

# 隐私信息设置 (https://gohugo.io/about/hugo-and-gdpr/)
[privacy]
320 321 322 323 324 325
  [privacy.googleAnalytics]
    anonymizeIP = true

  [privacy.youtube]
    privacyEnhanced = true

D
Dillon 已提交
326 327
# 用于输出 Markdown 格式文档的设置
[mediaTypes]
328 329 330
  [mediaTypes."text/plain"]
    suffixes = ["md"]

D
Dillon 已提交
331 332
# 用于输出 Markdown 格式文档的设置
[outputFormats.MarkDown]
333 334 335 336
  mediaType = "text/plain"
  isPlainText = true
  isHTML = false

D
Dillon 已提交
337 338
# 用于 Hugo 输出文档的设置
[outputs]
339 340 341 342 343
  home = ["HTML", "RSS"]
  page = ["HTML", "MarkDown"]
  section = ["HTML", "RSS"]
  taxonomy = ["HTML", "RSS"]
  taxonomyTerm = ["HTML"]