You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

27 lines
1.5 KiB

{
"name": "sha",
"version": "1.0.1",
"description": "Check and get file hashes",
"scripts": {
"test": "mocha -R list"
},
"repository": {
"type": "git",
"url": "https://github.com/ForbesLindesay/sha.git"
},
"license": "BSD",
"optionalDependencies": {
"graceful-fs": "1.2"
},
"devDependencies": {
"mocha": "~1.9.0"
},
"readme": "# sha\r\n\r\nCheck and get file hashes (using any algorithm)\r\n\r\n[![Build Status](https://travis-ci.org/ForbesLindesay/sha.png?branch=master)](https://travis-ci.org/ForbesLindesay/sha)\r\n[![Dependency Status](https://gemnasium.com/ForbesLindesay/sha.png)](https://gemnasium.com/ForbesLindesay/sha)\r\n\r\n## Installation\r\n\r\n $ npm install sha\r\n\r\n## API\r\n\r\n### check(fileName, expected, [options,] cb)\r\n\r\nAsynchronously check that `fileName` has a \"hash\" of `expected`. The callback will be called with either `null` or an error (indicating that they did not match).\r\n\r\nOptions:\r\n\r\n- algorithm: defaults to `sha1` and can be any of the algorithms supported by `crypto.createHash`\r\n\r\n### get(fileName, [options,] cb)\r\n\r\nAsynchronously get the \"hash\" of `fileName`. The callback will be called with an optional `error` object and the (lower cased) hex digest of the hash.\r\n\r\nOptions:\r\n\r\n- algorithm: defaults to `sha1` and can be any of the algorithms supported by `crypto.createHash`\r\n\r\n## License\r\n\r\nBSD\r\n",
"readmeFilename": "README.md",
"_id": "sha@1.0.1",
"dependencies": {
"graceful-fs": "1.2"
},
"_from": "sha@~1.0.1"
}