IT数码 购物 网址 头条 软件 日历 阅读 图书馆
TxT小说阅读器
↓语音阅读,小说下载,古典文学↓
图片批量下载器
↓批量下载图片,美女图库↓
图片自动播放器
↓图片自动播放器↓
一键清除垃圾
↓轻轻一点,清除系统垃圾↓
开发: C++知识库 Java知识库 JavaScript Python PHP知识库 人工智能 区块链 大数据 移动开发 嵌入式 开发工具 数据结构与算法 开发测试 游戏开发 网络协议 系统运维
教程: HTML教程 CSS教程 JavaScript教程 Go语言教程 JQuery教程 VUE教程 VUE3教程 Bootstrap教程 SQL数据库教程 C语言教程 C++教程 Java教程 Python教程 Python3教程 C#教程
数码: 电脑 笔记本 显卡 显示器 固态硬盘 硬盘 耳机 手机 iphone vivo oppo 小米 华为 单反 装机 图拉丁
 
   -> 开发工具 -> Hugo项目实战-集成评论博客添加评论功能 -> 正文阅读

[开发工具]Hugo项目实战-集成评论博客添加评论功能

实践效果

在这里插入图片描述
在这里插入图片描述

在这里插入图片描述
在这里插入图片描述

Quick Start

Install Hugo

brew install hugo
# or
port install hugo

hugo version

Create a New Site

hugo new site quickstart

Add a Theme

cd quickstart
git init
git submodule add https://github.com/shenhonglei/airspace-hugo.git themes/airspace-hugo

Then, add the theme to the site configuration:

echo 'theme = "ananke"' >> config.toml

Add Some Content

You can manually create content files (for example as content/<CATEGORY>/<FILE>.<FORMAT>) and provide metadata in them, however you can use the new command to do a few things for you (like add title and date):

hugo new posts/my-first-post.md

Start the Hugo server

Now, start the Hugo server with drafts enabled:

hugo server -D

Navigate to your new site at http://localhost:1313/.

Build static pages

It is simple. Just call:

hugo -D

Output will be in ./public/ directory by default (-d/--destination flag to change it, or set publishdir in the config file).

Theme Installation

使用模板方法一

git clone https://github.com/shenhonglei/airspace-hugo.git
cd exampleSite/
hugo server --themesDir ../..

使用模板方法二

#创建一个新的项目
hugo new site demo
# 主题模板安装
#下载主题https://github.com/shenhonglei/airspace-hugo.git
cd demo/themes
将下载的airspace-hugo copy到themes,然后将exampleSite目录的内容copy到demo目录,替换全部。
#运行
hugo server 
#访问
http://localhost:1313

个人博客快速建站

快速下载Themefisher模板,每个模板都有自己的文档、支持、持续更新内容。

eg:github-模板代码-airspace-hugoairspace-hugo使用文档

然后再参照,GitHub Actions 自动化部署 Hugo for GitHub Pages,自动化部署。

申请域名,解析服务等。

个人博客仓库名:xxxxx.github.io

Your GitHub Pages site is currently being built from the master branc:
master/root

Custom domain:xxxx.com
Enforce HTTPS :yes

hexo 博客添加评论功能

设置一个评论系统

  • 多说

  • 网易云跟帖

  • 畅言

  • 来必力(LiveRe)

  • Disqus

  • Hypercomments

  • valine

    Valine 诞生于2017年8月7日,是一款基于LeanCloud的快速、简洁且高效的无后端评论系统。 理论上支持但不限于静态博客,目前已有HexoJekyllTypechoHugoGhost 等博客程序在使用Valine。

    特性

  • Github大礼包:gitmentgitalk(推荐),gitter(推荐); 三个都支持Markdown;

    原则上来说比较靠谱的是gitment(依托于github issue,能够自己管理,而且被墙的概率小),不过兼容性不太好(需要chrome内核才行)。

    Gitalk 是一个基于 GitHub Issue 和 Preact 开发的评论插件。

    特性

    • 使用 GitHub 登录
    • 支持多语言 [en, zh-CN, zh-TW, es-ES, fr, ru, de, pl, ko]
    • 支持个人或组织
    • 无干扰模式(设置 distractionFreeMode 为 true 开启)
    • 快捷键提交评论 (cmd|ctrl + enter)
  开发工具 最新文章
Postman接口测试之Mock快速入门
ASCII码空格替换查表_最全ASCII码对照表0-2
如何使用 ssh 建立 socks 代理
Typora配合PicGo阿里云图床配置
SoapUI、Jmeter、Postman三种接口测试工具的
github用相对路径显示图片_GitHub 中 readm
Windows编译g2o及其g2o viewer
解决jupyter notebook无法连接/ jupyter连接
Git恢复到之前版本
VScode常用快捷键
上一篇文章      下一篇文章      查看所有文章
加:2022-04-22 18:57:14  更:2022-04-22 18:59:23 
 
开发: C++知识库 Java知识库 JavaScript Python PHP知识库 人工智能 区块链 大数据 移动开发 嵌入式 开发工具 数据结构与算法 开发测试 游戏开发 网络协议 系统运维
教程: HTML教程 CSS教程 JavaScript教程 Go语言教程 JQuery教程 VUE教程 VUE3教程 Bootstrap教程 SQL数据库教程 C语言教程 C++教程 Java教程 Python教程 Python3教程 C#教程
数码: 电脑 笔记本 显卡 显示器 固态硬盘 硬盘 耳机 手机 iphone vivo oppo 小米 华为 单反 装机 图拉丁

360图书馆 购物 三丰科技 阅读网 日历 万年历 2024年6日历 -2024/6/27 1:26:44-

图片自动播放器
↓图片自动播放器↓
TxT小说阅读器
↓语音阅读,小说下载,古典文学↓
一键清除垃圾
↓轻轻一点,清除系统垃圾↓
图片批量下载器
↓批量下载图片,美女图库↓
  网站联系: qq:121756557 email:121756557@qq.com  IT数码