<commit_before>var log = require('npmlog')
  , gcr = require('./gcr')
  , spawn = require('child_process').spawn
  , utils = exports

utils.genSSHKey = function(cb) {
  var args = [
      '-t'
    , 'rsa'
    , '-f'
    , '~/.ssh/gcr'
    , '-N'
    , '""'
  ]
  var child = spawn('ssh-keygen', args, {
      env: process.env
    , cwd: process.cwd()
  })
  child.stdout.pipe(process.stdout)
  child.stderr.pipe(process.stderr)
  child.on('exit', function(code) {
    if (code !== 0) {
      return cb && cb(new Error('Exited with code: '+code))
    }
    return cb && cb()
  })
}<commit_msg>Use child_process.exec instead of child_process.spawn<commit_after>var log = require('npmlog')
  , gcr = require('./gcr')
  , exec = require('child_process').exec
  , utils = exports

utils.genSSHKey = function(cb) {
  var cmd = 'ssh-keygen -t rsa -f ~/.ssh/gcr -N ""'
  exec(cmd, {
      env: process.env
    , cwd: process.cwd()
  }, function(err, stdout, stderr) {
    if (err) return cb && cb(err)
    return cb && cb(null, stdout)
  })
}
{'fraction_non_alphanumeric': 0.18762088974854932, 'fraction_numerical': 0.0009671179883945841, 'mean_word_length': 2.75, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4956933', 'n_tokens_mistral': 401, 'n_tokens_neox': 395, 'n_words': 83}