hexo icon indicating copy to clipboard operation
hexo copied to clipboard

the compiled result of 'hexo g' is different with 'hexo s'. Help!

Open AlbertXiao1994 opened this issue 8 years ago • 2 comments

Environment Info

Node version(node -v): v8.9.0

Your site _config.yml(Optional): https://github.com/AlbertXiao1994/albertxiao1994.github.io/blob/hexo/_config.yml

Your theme _config.yml (Optional): https://github.com/AlbertXiao1994/albertxiao1994.github.io/blob/hexo/themes/memory/_config.yml

Hexo and Plugin version(npm ls --depth 0): [email protected] D:\Github\blog +-- [email protected] +-- [email protected] +-- [email protected] +-- [email protected] +-- [email protected] +-- UNMET DEPENDENCY hexo-generator-searchdb@^1.0.8 +-- [email protected] +-- [email protected] +-- [email protected] +-- [email protected] +-- [email protected] `-- [email protected]

npm ERR! missing: hexo-generator-searchdb@^1.0.8, required by [email protected] npm ERR! missing: [email protected], required by [email protected] npm ERR! missing: [email protected], required by [email protected] npm ERR! missing: [email protected], required by [email protected] npm ERR! missing: [email protected], required by [email protected] npm ERR! missing: [email protected], required by [email protected] npm ERR! missing: [email protected], required by [email protected] npm ERR! missing: [email protected], required by [email protected] npm ERR! missing: [email protected], required by [email protected] npm ERR! missing: [email protected], required by [email protected] npm ERR! missing: [email protected], required by [email protected]

For BUG

For question

I use swig to write my theme, but I cannot get correct result when I use 'hexo g'. However, I get what I wanna when I use 'hexo s'. It's obvious there is something bad in compiling and generating 'public' folder, while 'hexo s' works well. How Can I solve it?

For feature request

AlbertXiao1994 avatar Jan 20 '18 07:01 AlbertXiao1994

Close as duplicate. This is a known issue. https://github.com/hexojs/hexo/issues/2451

NoahDragon avatar Jan 30 '18 19:01 NoahDragon

partial header should not be cached. https://github.com/AlbertXiao1994/albertxiao1994.github.io/blob/hexo/themes/memory/layout/_layout.swig#L25

{{ partial('_partials/header.swig', {}, {cache: theme.cache.enable}) }}

see https://github.com/hexojs/hexo/pull/3756#issuecomment-540286802

dailyrandomphoto avatar Oct 10 '19 03:10 dailyrandomphoto