將 Hexo 部落格更新至 6.3 版本

做法

修改 package.json 檔,更新 Hexo 及依賴套件的版本。

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
{
"name": "hexo-site",
"version": "0.0.0",
"private": true,
"scripts": {
"build": "hexo generate",
"clean": "hexo clean",
"deploy": "hexo deploy",
"serve": "hexo server"
},
"hexo": {
"version": "6.3.0"
},
"dependencies": {
"hexo": "^6.3.0",
"hexo-deployer-git": "^3.0.0",
"hexo-deployer-rsync": "^1.0.0",
"hexo-generator-archive": "^1.0.0",
"hexo-generator-category": "^1.0.0",
"hexo-generator-feed": "^3.0.0",
"hexo-generator-index": "^2.0.0",
"hexo-generator-search": "^2.4.3",
"hexo-generator-tag": "^1.0.0",
"hexo-renderer-ejs": "^2.0.0",
"hexo-renderer-marked": "^5.0.0",
"hexo-renderer-stylus": "^2.1.0",
"hexo-server": "^3.0.0"
}
}

修改 _config.yml 檔,將 external_link 屬性改為物件。

1
2
3
4
external_link:
enable: true # Open external links in new tab
field: site # Apply to the whole site
exclude: ''

修改 .nvmrc 檔,改為相容的 Node 版本。

1
v12.22.12

修改 scaffolds/post.md 檔,將 permalink 欄位移除。

1
2
3
4
5
6
---
title: {{ title }}
date: {{ date }}
tags:
categories:
---

將所有文章的 permalink 欄位移除。

1
permalink: