• 请不要在回答技术问题时复制粘贴 AI 生成的内容
stdying
V2EX  ›  程序员

hexo 文章生成时间问题

  •  
  •   stdying · Oct 27, 2015 · 9202 views
    This topic created in 4039 days ago, the information mentioned may be changed or developed.
    初次使用 hexo 写博客,文章写作时间是文本生成时的系统时间,如果文章拷贝到其他目录生成时间就会改变。

    以后要是换台电脑,文章岂不是都是最新生成。

    有没有什么可以修改的方法
    5 replies  •  2015-10-28 22:15:27 +08:00
    guoer
    guoer
    Oct 27, 2015
    2
    可以在.md 中定义时间吧
    date: 2015-01-19 00:34:14
    类似这种
    stdying
    stdying
    OP
    Oct 28, 2015
    3
    @guoer 好的,谢谢。
    stdying
    stdying
    OP
    Oct 28, 2015
    4
    @guchengf 谢谢,文档看到过,只是没明白什么意思
    i36lib
    i36lib
    Oct 28, 2015
    5
    @guoer 说的对,就是在文章的 md 文档前面加 date: ,这个时间的格式可以在你 blog 目录下的_config.yml 中通过 date_format: YYYY-MM-DD HH:mm:ss 来指定。
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Privacy   ·   Solana   ·   1090 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 29ms · UTC 18:26 · PVG 02:26 · LAX 10:26 · JFK 13:26
    ♥ Do have faith in what you're doing.