lib/cli/job.js
function copy(cb) {
  return function (existingName, newName, args) {
    function resultCb(result) {
      console.log(text.__('Job %s was copied to job %s'), existingName, newName);
    }
    function jenkinsCb(jenkins) {
      jenkins.copyJob(existingName, newName, cli.exitCb(null, resultCb));
    }
    cb(args, jenkinsCb);
  };
}
function copy(cb) {
  return function (existingName, newName, args) {
    function resultCb(result) {
      console.log(text.__('Job %s was copied to job %s'), existingName, newName);
    }
    function jenkinsCb(jenkins) {
      jenkins.copyJob(existingName, newName, cli.exitCb(null, resultCb));
    }
    cb(args, jenkinsCb);
  };
}
function copy ( cb ) { return function ( existingName , newName , args ) { function resultCb ( result ) { console . log ( text . __ ( 'Job %s was copied to job %s' ) , existingName , newName ) ; } function jenkinsCb ( jenkins ) { jenkins . copyJob ( existingName , newName , cli . exitCb ( null , resultCb ) ) ; } cb ( args , jenkinsCb ) ; } ; }
Get a handler that calls Jenkins API to copy a job into a new job.
Success job copy message will be logged when there's no error.

@param {Function} cb: callback for argument handling
@return Jenkins API handler function
Get a handler that calls Jenkins API to copy a job into a new job . Success job copy message will be logged when there s no error .