code: function execute(args, live, silent) {
    const env = Object.assign({}, process.env);
    return new Promise((resolve, reject) => {
      if (live === true) {
        const pid = childProcess.spawn(getPath(), args, {
          env,
          stdio: ['inherit', silent ? 'pipe' : 'inherit', 'inherit'],
        });
        pid.on('exit', () => {
          resolve();
        });
      } else {
        childProcess.execFile(getPath(), args, { env }, (err, stdout) => {
          if (err) {
            reject(err);
          } else {
            resolve(stdout);
          }
        });
      }
    });
  }
docs: Runs `sentry-cli` with the given command line arguments.
  
  Use {@link prepareCommand} to specify the command and add arguments for command-
  specific options. For top-level options, use {@link serializeOptions} directly.
  
  The returned promise resolves with the standard output of the command invocation
  including all newlines. In order to parse this output, be sure to trim the output
  first.
  
  If the command failed to execute, the Promise rejects with the error returned by the
  CLI. This error includes a `code` property with the process exit status.
  
  @example
  const output = await execute(['--version']);
  expect(output.trim()).toBe('sentry-cli x.y.z');
  
  @param {string[]} args Command line arguments passed to `sentry-cli`.
  @param {boolean} live We inherit stdio to display `sentry-cli` output directly.
  @param {boolean} silent Disable stdout for silents build (CI/Webpack Stats, ...)
  @returns {Promise.<string>} A promise that resolves to the standard output.