app构建

登录github账号,随后访问settings -> Develpoer setting -> OAuth Apps生成一个自定义app用于gitalk链接

image-20240126143302967

配置完成,可进一步完善,主要获取到Client ID、Client secrets两个参数(注意保护好参数信息,避免被滥用)


修改_config_butterfly.yml

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
comments:
# Up to two comments system, the first will be shown as default
# Choose: Disqus/Disqusjs/Livere/Gitalk/Valine/Waline/Utterances/Facebook Comments/Twikoo/Giscus/Remark42/Artalk
use: Gitalk # Valine,Disqus
text: true # Display the comment name next to the button
# lazyload: The comment system will be load when comment element enters the browser's viewport.
# If you set it to true, the comment count will be invalid
lazyload: true
count: true # Display comment count in post's top_img
card_post_count: true # Display comment count in Home Page


gitalk:
client_id: 对应Client ID
client_secret: 对应Client secrets
repo: 对应存储的仓库名
owner: github用户名
admin: 仓库的拥有者、协作者
option:


启动项目

本地只能看看gittalk是否已启动,想要测试完整效果需要部署到自己项目里面