code: function execCmd(i) {
      var cmd = cmdlines[i];
      if (!cmd) return;
  
      var child = exec(cmd,
          function (error, stdout, stderr) {
              if (stdout) {
                  console.log('-- exec stdout: ');
                  console.log(stdout);
              }
              if (stderr) {
                  console.log('-- exec stderr: ');
                  console.log(stderr);
              }
              if (error) {
                  console.log('-- exec error: ');
                  console.log(error);
              }
  
              execCmd(++i);
          });
  }
docs: console.log(cmdlines);