Hexo Deployment issues: Error:spawn git ENOENT
Preface
In the previous article Hexo the deployment of a free web application on GitHub, there was a problem error:spawn git enoent was not resolved, and the same problem arose when deploying on another machine today, and finally found a solution. Problem Description
Execute Hexo D error
Error:spawn git ENOENT at
exports._errnoexception (util.js:746:11) at
Process.childprocess._handle.onexit ( child_process.js:1053:32) at
child_process.js:1144:20 at
process._tickcallback (node.js:355:11)
cause Analysis
The specific reason I also say not clear, there is a person on the net to start Git-server, also appeared the same problem. Therefore, HEXO deployment should also be a series of git command collection, need git-server support. Workaround
Add environment variables: C:\Program Files (x86) \git\bin; C:\Program Files (x86) \git\libexec\git-core, this solves the problem. Reference Documents
[Nodejs] A strange event happened in the Windows installation Git-server (solved)