Node client for the Jenkins API
npm install --save hjerling/node-jenkins
var Jenkins = require('node-jenkins');
var jenkins = new Jenkins('http://jenkins.org');
jenkins.lastBuildInfo('ibl', function (err, buildInfo) {
if (err) return console.error(err.message);
console.log('Last build result for ibl is ' + buildInfo.result);
});
Create a new Jenkins client.
- Request options to be able to access the jenkins server.
Get information about a job.
job_name
String
Get a list of all the jobs on this Jenkins server.
Get information about a build.
job_name
Stringbuild_number
Number
Get information about the last build.
job_name
String
Get build output for a build.
job_name
Stringbuild_number
Number
Trigger a build for a job.
job_name
String
Request to stop a build for a job.
job_name
Stringbuild_number
Number
Get current build queue.
- Fork it!
- Create your feature branch:
git checkout -b my-new-feature
- Commit your changes:
git commit -am 'Add some feature'
- Push to the branch:
git push origin my-new-feature
- Create new Pull Request.
Thanks to Robin Murphy for basic structure of module.