aboutsummaryrefslogtreecommitdiff
path: root/node_modules/crc32-stream
diff options
context:
space:
mode:
Diffstat (limited to 'node_modules/crc32-stream')
-rw-r--r--node_modules/crc32-stream/CHANGELOG.md12
-rw-r--r--node_modules/crc32-stream/LICENSE22
-rw-r--r--node_modules/crc32-stream/README.md79
-rw-r--r--node_modules/crc32-stream/lib/crc32-stream.js44
-rw-r--r--node_modules/crc32-stream/lib/deflate-crc32-stream.js69
-rw-r--r--node_modules/crc32-stream/lib/index.js10
-rw-r--r--node_modules/crc32-stream/package.json45
7 files changed, 0 insertions, 281 deletions
diff --git a/node_modules/crc32-stream/CHANGELOG.md b/node_modules/crc32-stream/CHANGELOG.md
deleted file mode 100644
index 2dd648590..000000000
--- a/node_modules/crc32-stream/CHANGELOG.md
+++ /dev/null
@@ -1,12 +0,0 @@
-## Changelog
-
-**2.0.0** — <small>_February 13, 2017_</small> — [Diff](https://github.com/archiverjs/node-crc32-stream/compare/1.0.1...2.0.0)
-
-- adopt nodejs core Hash API (GH #4)
-
-**1.0.1** — <small>_January 12, 2016_</small> — [Diff](https://github.com/archiverjs/node-crc32-stream/compare/1.0.0...1.0.1)
-
-- Switch to node-crc for performance (GH #3)
-- bump deps to ensure latest versions are used.
-
-[Release Archive](https://github.com/archiverjs/node-crc32-stream/releases) \ No newline at end of file
diff --git a/node_modules/crc32-stream/LICENSE b/node_modules/crc32-stream/LICENSE
deleted file mode 100644
index 819b403f0..000000000
--- a/node_modules/crc32-stream/LICENSE
+++ /dev/null
@@ -1,22 +0,0 @@
-Copyright (c) 2014 Chris Talkington, contributors.
-
-Permission is hereby granted, free of charge, to any person
-obtaining a copy of this software and associated documentation
-files (the "Software"), to deal in the Software without
-restriction, including without limitation the rights to use,
-copy, modify, merge, publish, distribute, sublicense, and/or sell
-copies of the Software, and to permit persons to whom the
-Software is furnished to do so, subject to the following
-conditions:
-
-The above copyright notice and this permission notice shall be
-included in all copies or substantial portions of the Software.
-
-THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
-OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
-HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
-WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
-FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
-OTHER DEALINGS IN THE SOFTWARE. \ No newline at end of file
diff --git a/node_modules/crc32-stream/README.md b/node_modules/crc32-stream/README.md
deleted file mode 100644
index a0b508054..000000000
--- a/node_modules/crc32-stream/README.md
+++ /dev/null
@@ -1,79 +0,0 @@
-# crc32-stream v2.0.0 [![Build Status](https://travis-ci.org/archiverjs/node-crc32-stream.svg?branch=master)](https://travis-ci.org/archiverjs/node-crc32-stream) [![Build status](https://ci.appveyor.com/api/projects/status/sy60s39cmyvd60i3/branch/master?svg=true)](https://ci.appveyor.com/project/ctalkington/node-crc32-stream/branch/master)
-
-crc32-stream is a streaming CRC32 checksumer. It uses [buffer-crc32](https://www.npmjs.org/package/buffer-crc32) behind the scenes to reliably handle binary data and fancy character sets. Data is passed through untouched.
-
-### Install
-
-```bash
-npm install crc32-stream --save
-```
-
-You can also use `npm install https://github.com/archiverjs/node-crc32-stream/archive/master.tar.gz` to test upcoming versions.
-
-### Usage
-
-#### CRC32Stream
-
-Inherits [Transform Stream](http://nodejs.org/api/stream.html#stream_class_stream_transform) options and methods.
-
-```js
-var CRC32Stream = require('crc32-stream');
-
-var source = fs.createReadStream('file.txt');
-var checksum = new CRC32Stream();
-
-checksum.on('end', function(err) {
- // do something with checksum.digest() here
-});
-
-// either pipe it
-source.pipe(checksum);
-
-// or write it
-checksum.write('string');
-checksum.end();
-```
-
-#### DeflateCRC32Stream
-
-Inherits [zlib.DeflateRaw](http://nodejs.org/api/zlib.html#zlib_class_zlib_deflateraw) options and methods.
-
-```js
-var DeflateCRC32Stream = require('crc32-stream').DeflateCRC32Stream;
-
-var source = fs.createReadStream('file.txt');
-var checksum = new DeflateCRC32Stream();
-
-checksum.on('end', function(err) {
- // do something with checksum.digest() here
-});
-
-// either pipe it
-source.pipe(checksum);
-
-// or write it
-checksum.write('string');
-checksum.end();
-```
-
-### Instance API
-
-#### digest()
-
-Returns the checksum digest in unsigned form.
-
-#### hex()
-
-Returns the hexadecimal representation of the checksum digest. (ie E81722F0)
-
-#### size(compressed)
-
-Returns the raw size/length of passed-through data.
-
-If `compressed` is `true`, it returns compressed length instead. (DeflateCRC32Stream)
-
-## Things of Interest
-
-- [Changelog](https://github.com/archiverjs/node-crc32-stream/releases)
-- [Contributing](https://github.com/archiverjs/node-crc32-stream/blob/master/CONTRIBUTING.md)
-- [MIT License](https://github.com/archiverjs/node-crc32-stream/blob/master/LICENSE-MIT) \ No newline at end of file
diff --git a/node_modules/crc32-stream/lib/crc32-stream.js b/node_modules/crc32-stream/lib/crc32-stream.js
deleted file mode 100644
index f0b0ee6c7..000000000
--- a/node_modules/crc32-stream/lib/crc32-stream.js
+++ /dev/null
@@ -1,44 +0,0 @@
-/**
- * node-crc32-stream
- *
- * Copyright (c) 2014 Chris Talkington, contributors.
- * Licensed under the MIT license.
- * https://github.com/archiverjs/node-crc32-stream/blob/master/LICENSE-MIT
- */
-var inherits = require('util').inherits;
-var Transform = require('readable-stream').Transform;
-
-var crc32 = require('crc').crc32;
-
-var CRC32Stream = module.exports = function CRC32Stream(options) {
- Transform.call(this, options);
- this.checksum = new Buffer(4);
- this.checksum.writeInt32BE(0, 0);
-
- this.rawSize = 0;
-};
-
-inherits(CRC32Stream, Transform);
-
-CRC32Stream.prototype._transform = function(chunk, encoding, callback) {
- if (chunk) {
- this.checksum = crc32(chunk, this.checksum);
- this.rawSize += chunk.length;
- }
-
- callback(null, chunk);
-};
-
-CRC32Stream.prototype.digest = function(encoding) {
- var checksum = new Buffer(4);
- checksum.writeUInt32BE(this.checksum >>> 0, 0);
- return encoding ? checksum.toString(encoding) : checksum;
-};
-
-CRC32Stream.prototype.hex = function() {
- return this.digest('hex').toUpperCase();
-};
-
-CRC32Stream.prototype.size = function() {
- return this.rawSize;
-};
diff --git a/node_modules/crc32-stream/lib/deflate-crc32-stream.js b/node_modules/crc32-stream/lib/deflate-crc32-stream.js
deleted file mode 100644
index d55c2032c..000000000
--- a/node_modules/crc32-stream/lib/deflate-crc32-stream.js
+++ /dev/null
@@ -1,69 +0,0 @@
-/**
- * node-crc32-stream
- *
- * Copyright (c) 2014 Chris Talkington, contributors.
- * Licensed under the MIT license.
- * https://github.com/archiverjs/node-crc32-stream/blob/master/LICENSE-MIT
- */
-var zlib = require('zlib');
-var inherits = require('util').inherits;
-
-var crc32 = require('crc').crc32;
-
-var DeflateCRC32Stream = module.exports = function (options) {
- zlib.DeflateRaw.call(this, options);
-
- this.checksum = new Buffer(4);
- this.checksum.writeInt32BE(0, 0);
-
- this.rawSize = 0;
- this.compressedSize = 0;
-
- // BC v0.8
- if (typeof zlib.DeflateRaw.prototype.push !== 'function') {
- this.on('data', function(chunk) {
- if (chunk) {
- this.compressedSize += chunk.length;
- }
- });
- }
-};
-
-inherits(DeflateCRC32Stream, zlib.DeflateRaw);
-
-DeflateCRC32Stream.prototype.push = function(chunk, encoding) {
- if (chunk) {
- this.compressedSize += chunk.length;
- }
-
- return zlib.DeflateRaw.prototype.push.call(this, chunk, encoding);
-};
-
-DeflateCRC32Stream.prototype.write = function(chunk, enc, cb) {
- if (chunk) {
- this.checksum = crc32(chunk, this.checksum);
- this.rawSize += chunk.length;
- }
-
- return zlib.DeflateRaw.prototype.write.call(this, chunk, enc, cb);
-};
-
-DeflateCRC32Stream.prototype.digest = function(encoding) {
- var checksum = new Buffer(4);
- checksum.writeUInt32BE(this.checksum >>> 0, 0);
- return encoding ? checksum.toString(encoding) : checksum;
-};
-
-DeflateCRC32Stream.prototype.hex = function() {
- return this.digest('hex').toUpperCase();
-};
-
-DeflateCRC32Stream.prototype.size = function(compressed) {
- compressed = compressed || false;
-
- if (compressed) {
- return this.compressedSize;
- } else {
- return this.rawSize;
- }
-};
diff --git a/node_modules/crc32-stream/lib/index.js b/node_modules/crc32-stream/lib/index.js
deleted file mode 100644
index 31187e38e..000000000
--- a/node_modules/crc32-stream/lib/index.js
+++ /dev/null
@@ -1,10 +0,0 @@
-/**
- * node-crc32-stream
- *
- * Copyright (c) 2014 Chris Talkington, contributors.
- * Licensed under the MIT license.
- * https://github.com/archiverjs/node-crc32-stream/blob/master/LICENSE-MIT
- */
-exports = module.exports = require('./crc32-stream');
-exports.CRC32Stream = exports;
-exports.DeflateCRC32Stream = require('./deflate-crc32-stream'); \ No newline at end of file
diff --git a/node_modules/crc32-stream/package.json b/node_modules/crc32-stream/package.json
deleted file mode 100644
index d7ecbb3b5..000000000
--- a/node_modules/crc32-stream/package.json
+++ /dev/null
@@ -1,45 +0,0 @@
-{
- "name": "crc32-stream",
- "version": "2.0.0",
- "description": "a streaming CRC32 checksumer",
- "homepage": "https://github.com/archiverjs/node-crc32-stream",
- "author": {
- "name": "Chris Talkington",
- "url": "http://christalkington.com/"
- },
- "repository": {
- "type": "git",
- "url": "https://github.com/archiverjs/node-crc32-stream.git"
- },
- "bugs": {
- "url": "https://github.com/archiverjs/node-crc32-stream/issues"
- },
- "license": "MIT",
- "main": "lib/index.js",
- "files": [
- "lib"
- ],
- "engines": {
- "node": ">= 0.10.0"
- },
- "scripts": {
- "test": "mocha --reporter dot"
- },
- "dependencies": {
- "crc": "^3.4.4",
- "readable-stream": "^2.0.0"
- },
- "devDependencies": {
- "chai": "^3.4.0",
- "mocha": "^3.2.0"
- },
- "keywords": [
- "crc32-stream",
- "crc32",
- "stream",
- "checksum"
- ],
- "publishConfig": {
- "registry": "https://registry.npmjs.org/"
- }
-}