We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
hexo generate
有关Issue:#32 #37
观察到:清除所有post的categories后,第一次执行hexo generate或者hexo serve,生成的网站中categories为空,以后再执行generate或serve则产生正常结果。
hexo serve
问题在于,插件通过重写data.full_source来设置自动识别的categories,但是第一次hexo generate后修改的full_source在本次generate过程中不会生效,因为markdown已经被parse过并传递给插件处理了,修改了源文件中的categories后要到下一次generate时才会被识别到。而github pages / cf pages只会执行一次generate,因此在类似云部署环境中,插件无法生效。
data.full_source
可能需要通过强制更新data.categories,或者强制重新读取一次Post来解决此问题
The text was updated successfully, but these errors were encountered:
这个问题能复现吗?解决了吗
Sorry, something went wrong.
能复现,挺好复现的😂 随便hexo init创建一个博客,塞一点不写category的post进去,然后generate,或者serve 第一次生成出来的category页面是空的
刚刚尝试过直接在代码里面覆写data.categories,但是覆写完好像生效不了,emm,感觉不太好弄
No branches or pull requests
有关Issue:#32 #37
观察到:清除所有post的categories后,第一次执行
hexo generate
或者hexo serve
,生成的网站中categories为空,以后再执行generate或serve则产生正常结果。问题在于,插件通过重写
data.full_source
来设置自动识别的categories,但是第一次hexo generate
后修改的full_source在本次generate过程中不会生效,因为markdown已经被parse过并传递给插件处理了,修改了源文件中的categories后要到下一次generate时才会被识别到。而github pages / cf pages只会执行一次generate,因此在类似云部署环境中,插件无法生效。可能需要通过强制更新data.categories,或者强制重新读取一次Post来解决此问题
The text was updated successfully, but these errors were encountered: