lib/install/rust.js
function sha256stream() {
  var sha256 = createHash('sha256');
  var stream = new Transform();
  stream._transform = function(chunk, encoding, callback) {
    this.push(chunk);
    sha256.update(chunk);
    callback();
  };
  stream.on('finish', () => {
    stream.emit('sha256', sha256.digest('hex'));
  });
  return stream;
}
function sha256stream() {
  var sha256 = createHash('sha256');
  var stream = new Transform();
  stream._transform = function(chunk, encoding, callback) {
    this.push(chunk);
    sha256.update(chunk);
    callback();
  };
  stream.on('finish', () => {
    stream.emit('sha256', sha256.digest('hex'));
  });
  return stream;
}
/* istanbul ignore next