github+dexo搭建博客时dexo d出错的解决办法

部署github博客是部署的时候执行dexo d命令时报以下错误

var foo = 'bar';error: src refspec HEAD does not match any error: failed to push some refs to 
'https://github.com/bing/bing.github.io.git' FATAL Something's wrong. Maybe you can find the solution here: 
https://hexo.io/docs/troubleshooting.html Error: Spawn failed at ChildProcess. (E:\blog\node_modules\hexo-
util\lib\spawn.js:51:21) at ChildProcess.emit (events.js:210:5) at ChildProcess.cp.emit (E:\blog\node_modules\cross-
spawn\lib\enoent.js:34:29) at Process.ChildProcess._handle.onexit (internal/child_process.js:272:12)

解决办法:

  1. 删除.deploy_git文件后重新部署

  2. 依次执行

dexo clean
dexo g
dexo d
  1. 根目录下的_config文件中的
// An highlighted block
deploy: 
  type: git 
  repository: https://github.com/bing/bing.github.io.git 
  email: boatding@boatding.com 
  name: boatding
  branch: master 

你可能感兴趣的:(Java技术积累)