New issue

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 g`出错 #1913

Closed
dalufine opened this Issue Apr 24, 2016 · 4 comments

Comments

4 participants
@dalufine
Copy link

dalufine commented Apr 24, 2016

INFO Start processing
FATAL Something's wrong. Maybe you can find the solution here: http://hexo.io/docs/troubleshooting.html
TypeError: Cannot set property 'lastIndex' of undefined
at highlight (/Users/dalu/Documents/blog/node_modules/highlight.js/lib/highlight.js:471:35)
at /Users/dalu/Documents/blog/node_modules/highlight.js/lib/highlight.js:521:21
at Array.forEach (native)
at Object.highlightAuto (/Users/dalu/Documents/blog/node_modules/highlight.js/lib/highlight.js:520:40)
at highlight (/Users/dalu/Documents/blog/node_modules/hexo-util/lib/highlight.js:98:19)
at highlightUtil (/Users/dalu/Documents/blog/node_modules/hexo-util/lib/highlight.js:21:14)
at /Users/dalu/Documents/blog/node_modules/hexo/lib/plugins/filter/before_post_render/backtick_code_block.js:49:15
at String.replace (native)
at Hexo.backtickCodeBlock (/Users/dalu/Documents/blog/node_modules/hexo/lib/plugins/filter/before_post_render/backtick_code_block.js:15:31)
at Hexo.tryCatcher (/Users/dalu/Documents/blog/node_modules/bluebird/js/release/util.js:16:23)
at Hexo. (/Users/dalu/Documents/blog/node_modules/bluebird/js/release/method.js:15:34)
at /Users/dalu/Documents/blog/node_modules/hexo/lib/extend/filter.js:68:35
at tryCatcher (/Users/dalu/Documents/blog/node_modules/bluebird/js/release/util.js:16:23)
at Object.gotValue (/Users/dalu/Documents/blog/node_modules/bluebird/js/release/reduce.js:145:18)
at Object.gotAccum (/Users/dalu/Documents/blog/node_modules/bluebird/js/release/reduce.js:134:25)
at Object.tryCatcher (/Users/dalu/Documents/blog/node_modules/bluebird/js/release/util.js:16:23)
at Promise._settlePromiseFromHandler (/Users/dalu/Documents/blog/node_modules/bluebird/js/release/promise.js:502:31)
at Promise._settlePromise (/Users/dalu/Documents/blog/node_modules/bluebird/js/release/promise.js:559:18)
at Promise._settlePromiseCtx (/Users/dalu/Documents/blog/node_modules/bluebird/js/release/promise.js:596:10)
at Async._drainQueue (/Users/dalu/Documents/blog/node_modules/bluebird/js/release/async.js:143:12)
at Async._drainQueues (/Users/dalu/Documents/blog/node_modules/bluebird/js/release/async.js:148:10)
at Immediate.Async.drainQueues as _onImmediate

package.json

{
  "name": "hexo-site",
  "version": "0.0.0",
  "private": true,
  "hexo": {
    "version": "3.2.0"
  },
  "dependencies": {
    "hexo": "^3.2.0",
    "hexo-generator-archive": "^0.1.4",
    "hexo-generator-category": "^0.1.3",
    "hexo-generator-index": "^0.2.0",
    "hexo-generator-tag": "^0.2.0",
    "hexo-renderer-ejs": "^0.2.0",
    "hexo-renderer-marked": "^0.2.10",
    "hexo-renderer-stylus": "^0.3.1",
    "hexo-server": "^0.2.0"
  }
}
@dalufine

This comment has been minimized.

Copy link
Author

dalufine commented Apr 25, 2016

highlight.js

@dalufine dalufine closed this Apr 25, 2016

@ding112

This comment has been minimized.

Copy link

ding112 commented Sep 8, 2016

_config.yml中auto_detect设为false

@cocobear

This comment has been minimized.

Copy link

cocobear commented Dec 28, 2018

_config.yml中auto_detect设为false

这样做的话这个配置就没有意义了,有没有人研究过这个呢?

@counter2015

This comment has been minimized.

Copy link

counter2015 commented Jan 17, 2019

_config.yml中auto_detect设为false

这样做的话这个配置就没有意义了,有没有人研究过这个呢?

我也遇到了同样的问题,添加某篇新文章时出现,往里面加入gh-md-toc生成的目录是报错

但是把出问题的文章移走,重新hexo g,再移回来,再次hexo g后就没有问题了

玄学BUG

刚刚又看了下发现文末有一个多余的空代码块,不知道是不是因为这个原因 😂

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment