Comments (3)
现在弄清原因了,因为更改thread-key 时,没有预料到多说本身自带更改thread-key 功能,而是导出全部数据,然后手动修改thread-key 导入。本身这个行为也是没有问题的,但是导出后我随即删除了后台所有的评论和文章。删除评论不会导致问题,而删除文章会引发一个非常麻烦的问题:多说中每个文章都由一个id 来标识,再次添加文章后,id 已经变更,所以导入修改后的评论数据,仍然无法与文章对应。导致全部评论丢失。
解决方法只有一个,对应地修改json 中的文章id,但是太过繁琐,考虑再三决定放弃所有评论。
一个教训——先弄清楚产品的功能再使用。
from arondight.github.io.
顺便记录一下多说更改thread-key 的正确流程:
- 更改站点文章的thread-key
- 多说后台中选择文章选项卡,点击编辑,填入新的thread-key
from arondight.github.io.
已经找回所有评论:
- 删除整个多说站点,新建多说站点后与网站关联
- 每个文章下面评论一下,然后导出数据
- 根据新的json,分别替换旧json 的
thread_id
和thread_key
字段 - 删除所有的
site_id
字段,删除"threads"
部分
非常感谢jq,这个软件完成了很棒的两个工作:
- 将json 转换为格式统一且易于阅读的排版
- 将unicode 编码转换为字符
否则完成这个工作是难以想象的。从冒出来这个点子到实施完毕,大约花了半小时。顺道感谢atom,有时候提供一个不支持正则表达式的替换功能是至关重要的。
from arondight.github.io.
Related Issues (12)
- hexo server 本地无法访问categories HOT 2
- hexo 部分参数提示未注册 HOT 1
- themes/init.sh 不应手动调用 HOT 1
- deploy 时应当试图克隆可能不存在的仓库并检出master 分支 HOT 3
- 构建脚本应当模块化
- 动态读取构建脚本中仓库的地址 HOT 1
- 不再使用litten/hexo-theme-yilia 中会引发bug 的thread-key
- init.sh 逻辑有问题
- generate.sh 执行时应当先试图清空public 目录
- deploy.sh 执行时应当先试图删除可能存在的.deploy_git 目录 HOT 1
- 需要一个update.sh HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from arondight.github.io.