0

I can't deploy?when I exc hexo server after hexo generate,I can see the page that should be.But when I exc hexo deploy It prompt:

To https://github.com/gabygoole/gabygoole.github.io.git
 ! [remote rejected] master -> master (failed to lock)
error: failed to push some refs to 'https://github.com/gabygoole/gabygoole.githu                                                               b.io.git'
FATAL Something's wrong. Maybe you can find the solution here: http://hexo.io/do                                                               cs/troubleshooting.html
Error: To https://github.com/gabygoole/gabygoole.github.io.git
 ! [remote rejected] master -> master (failed to lock)
error: failed to push some refs to 'https://github.com/gabygoole/gabygoole.githu                                                               b.io.git'


at ChildProcess.<anonymous> (C:\blog\node_modules\hexo-deployer-git\node_mod                                                               ules\hexo-util\lib\spawn.js:42:17)
at emitTwo (events.js:87:13)
at ChildProcess.emit (events.js:172:7)
at maybeClose (internal/child_process.js:818:16)
at Process.ChildProcess._handle.onexit (internal/child_process.js:211:5)
Gaby
  • 130
  • 1
  • 8

2 Answers2

0

The truth is,I add a file in GithHub remote master branch.But I do not add the file locally.When I forced-push to remote master branch,that means I delete the file.So,just make add the file locally,and push to remote master.everything will be fine!

Gaby
  • 130
  • 1
  • 8
0

My solution is:

$ cd .deploy_git/
$ git add .
$ cd ..
$ hexo clean && hexo g && hexo d

Then the problem fixed.

dekrt
  • 1