json - nodejs and gith doesn't work -


I am trying to create an autodetship with github, to execute this JS "server" Github to get the hook, this work is amazing, but I need to download a repository to run a script again, but this code does not execute my hook. Sh. I do not have a node experience before, so, I'm lost here.

  // Listen ports 9001 var gith = require ('gith'). Create (9001); // import execfile, run our bash script var execFile = ('child_process'). ExecFile; Gith ({repo: 'username / autodeploy'}). ('All', function (payload) {if (payload.branch === 'master') {// exec shell script execFile ('/ root / nodeapp /hook.sh', function (error, stdout, stderr) { // log success in some ways. Console ('exec completion');});}});  

OK, I was testing it manually and it seems that the problem is with gith ({.... which is inside it does not work, Anyone have any ideas?

OK, problem

 

P> On ('File: All', Function (Payload) {....

And that's my problem. MSCDX and @londarev, tell me to test Not.


Comments

Popular posts from this blog

java - org.apache.http.ProtocolException: Target host is not specified -

java - Gradle dependencies: compile project by relative path -

ruby on rails - Object doesn't support #inspect when used with .include -