<rss xmlns:atom="http://www.w3.org/2005/Atom" version="2.0">
    <channel>
        <title>备忘 - Category - ICHARM</title>
        <link>http://example.org/categories/%E5%A4%87%E5%BF%98/</link>
        <description>备忘 - Category - ICHARM</description>
        <generator>Hugo -- gohugo.io</generator><language>en-us</language><lastBuildDate>Sat, 01 Jul 2023 15:23:31 &#43;0000</lastBuildDate><atom:link href="http://example.org/categories/%E5%A4%87%E5%BF%98/" rel="self" type="application/rss+xml" /><item>
    <title>Hugo主题LoveIt使用遇到的问题</title>
    <link>http://example.org/hugo-loveit-using/index.zh_cn.html</link>
    <pubDate>Sat, 01 Jul 2023 15:23:31 &#43;0000</pubDate>
    <author>Elias</author>
    <guid>http://example.org/hugo-loveit-using/index.zh_cn.html</guid>
    <description><![CDATA[几年没写博客了，腾讯的云主机到期后，把博客从wordpress迁移到Hugo上面，主题使用的loveit，刚迁移过来，遇到不少问题，记录一下。
迁移 本来以为迁移很麻烦，没想到有这个工具 wordpress-to-hugo-exporter 安装好后直接把所有的文章都导出到Hugo格式还有静态文件，图片什么的一块整理好，省去了很多的工作。
然后就是针对每篇文章一个一个的优化，还是花了不少的精力。
代码高亮 使用loveit的默认配置，发现代码块渲染出来的样式与demosite上面不同，没有折叠和拷贝按钮。
处理这个问题需要在主题配置config.toml中添加下列配置:
# Markup related configuration in Hugo # Hugo 解析文档的配置 [markup] # Syntax Highlighting (https://gohugo.io/content-management/syntax-highlighting) # 语法高亮设置 (https://gohugo.io/content-management/syntax-highlighting) [markup.highlight] # false is a necessary configuration (https://github.com/dillonzq/LoveIt/issues/158) # false 是必要的设置 (https://github.com/dillonzq/LoveIt/issues/158) noClasses = false Refer: https://github.com/dillonzq/LoveIt/issues/361
封面图 创建一个posts，在md文档的同目录下放入封面图featured-image.jpg，通过下面方式引入：
--- title: 技嘉GIGABYTE B350M Gaming 3 关闭 secure boot images: [] resources: - name: &#34;featured-image&#34; src: &#34;featured-image.jpg&#34; --- 经过测试，没有正常显示封面图片。解决该问题有两种方式:
方式一
hugo中文档名称必须是index.xxx.md的格式，并且确保文档是在content/posts/下面，把文档换成index开后之后，通过上面方式引入封面图可以正常显示。
Refer: https://github.com/dillonzq/LoveIt/issues/582
方式二
封面图放在static目录下，然后在md文档的头部通过featuredImage的方式引入，如下]]></description>
</item>
</channel>
</rss>
