基于MovableType的chedong.com/tech 重构
📌 TLDR
把 tech/ 目录整体搬进 MovableType 的决策记录:要求是原文件名不变(保住 permalink)、内容和表现分离、在线编辑、能管理文章关联、有留言反馈。实现上只用首页/归档页的 %f 自定义文件名,取消月归档和分类归档,用 RelatedEntry 当标签。结论:发布系统完全可以没有"目录"—— 标签更扁平、不用预先定义分类、先写后分更贴近人的思路;另记下 MT 当时管不了 20k 以上的长文。
拖了3年了一直没做的一件事情:将以前tech/目录下的内容进行结构化管理,今天终于完成了。
4年前觉得自己做的这几个网页就是blog,从现在看,缺少了很多特征:可留言反馈,可RSS发布等。所以这次重构的系统选择我提出了以下几个要求: 1 文章按照指定文件名在根目录下导出:保持原有的链接不变(permalink); 2 模板话管理:省却使用sed批量替换的麻烦,内容和表现分离; 3 在线可编辑,而不是使用SFTP/FTP上传; 4 更好的管理文章之间的关联; 5 有反馈机制:留言,这对内容的修正很有好处;
最后终于选择了熟悉的MovableType通过一番设置,用了2个周末下班时间完成了。对mt的设置如下: 1 只保留首页/归档页 使用 %f 模式自定义文件名; 2 取消按月归档,取消按分类归档; 3 使用RelatedEntry插件实现标签分类;
同时也发现MT的一个缺点: 不能管理过长的文档(超过20k的),比如: Hello Unicode这篇文章中的3个实验不得不分拆离成了3篇文章;
现在chedong.com 主要有3个目录:都已经是结构化的数据了。 blog/ 个人blog tech/ 笔记 digest/ 文摘收藏归档
在这次重构中,发现完全没有目录机制的发布也是完全可行的,目录和标签分类(tag)的一个区别: 目录:需要考虑分类规则,需要预先定义,但计划赶不上变化; 标签:的主题可以完全不考虑分类规则,而且组织的更扁平;不需要预先定义,更符合用户的思维顺序,先书写后分类;
在线的内容管理一直是我非常感兴趣的一个领域,如何让内容在更长时期内保持“新鲜”也是一直在思考的一个问题。希望目前的解决方案能用的时间更长一些。
更新:2007-04-21 通过Google的站长工具获得了tech目录下文章引用统计 http://www.chedong.com/tech/lucene.html 1325 http://www.chedong.com/tech/google.html 1245 http://www.chedong.com/tech/google_url.html 1229 http://www.chedong.com/tech/awstats.html 1138 http://www.chedong.com/tech/ 908 http://www.chedong.com/tech/cvs_card.html 799 http://www.chedong.com/tech/hello_unicode.html 606 http://www.chedong.com/tech/google_ads.html 516 http://www.chedong.com/tech/cms.html 472 http://www.chedong.com/tech/link_pop_check.html 462 http://www.chedong.com/tech/cache.html 388 http://www.chedong.com/tech/rotate_merge_log.html 324 http://www.chedong.com/tech/apache_install.html 288 http://www.chedong.com/tech/indent_tools.html 234 http://www.chedong.com/tech/weblucene.html 229 http://www.chedong.com/tech/mysql.html 172 http://www.chedong.com/tech/compress.html 153 http://www.chedong.com/tech/ant.html 130 http://www.chedong.com/tech/study.html 101 http://www.chedong.com/tech/xslt.html 94 http://www.chedong.com/tech/weblog.html 79 http://www.chedong.com/tech/dev.html 71 http://www.chedong.com/tech/resin.html 68 http://www.chedong.com/tech/oracle.html 64 http://www.chedong.com/tech/oe2html.html 62 http://www.chedong.com/tech/click.html 57 http://www.chedong.com/tech/unicode_java.html 57 http://www.chedong.com/tech/comments.php 49 http://www.chedong.com/tech/Env.java 47 http://www.chedong.com/tech/HelloUnicode.java 46 http://www.chedong.com/tech/HelloUnicodeServlet.java 37 http://www.chedong.com/tech/comment.html 32 http://www.chedong.com/tech/nat.html 31 http://www.chedong.com/tech/google_xml_xslt.ppt 26 http://www.chedong.com/tech/default.html 23 http://www.chedong.com/tech/gnu.html 21 http://www.chedong.com/tech/jalopy.xml 21 http://www.chedong.com/tech/acdsee.html 15 http://www.chedong.com/tech/cvs.ppt 5
💬 历史评论
以下 4 条评论从旧版 Movable Type 博客迁移而来。 原始评论时间:2002–2016 年。
枫林 · 2007-04-13 23:31
貌似不错,左侧的相关文章看上去有点乱,统一下字符长度,任你有良好的的结构良好的导航,但是美工和用户体验是留住访客的两个重要方面,不可忽视,网站不管是设计还是重构,最终要面对的是用户,不是搜索引擎。
shunz · 2007-04-15 08:38
三个目录能否烧在一起提供一个rss输出呢?
Platinum · 2007-04-16 10:42
重不重构没啥区别……就是 txt 的也照样有价值
问题是啥时候能再写点新的……
孙波 · 2007-04-18 09:21
进来乍一看我以为是wordpress,后来看了一下知道原来不是。
1 文章按照指定文件名在根目录下导出:保持原有的链接不变(permalink); 2 模板话管理:省却使用sed批量替换的麻烦,内容和表现分离; 3 在线可编辑,而不是使用SFTP/FTP上传; 4 更好的管理文章之间的关联; 5 有反馈机制:留言,这对内容的修正很有好处;
这些要求还是非常有用的,不论对于搜索引擎、用户体验、还是管理者的操作。