lyxaira.glass 74ca844f42 Actualizacion cambios generados: seccion #12, #14 y #15. | 4 years ago | |
---|---|---|
.. | ||
LICENSE.md | 4 years ago | |
cli.js | 4 years ago | |
index.d.ts | 4 years ago | |
index.js | 4 years ago | |
package.json | 4 years ago | |
readme.md | 4 years ago |
Get the MD5-sum of a given file, with low memory usage, even on huge files.
npm install --save md5-file
const md5File = require('md5-file')
/* Async usage */
md5File('LICENSE.md').then((hash) => {
console.log(`The MD5 sum of LICENSE.md is: ${hash}`)
})
/* Sync usage */
const hash = md5File.sync('LICENSE.md')
console.log(`The MD5 sum of LICENSE.md is: ${hash}`)
$ md5-file LICENSE.md
ad1faf9381e43c471dc381c17a4ee4b6
md5File(path: string) => Promise<string>
Asynchronously get the MD5-sum of the file at path
.
Returns a Promise
that will be resolved with a string containing the MD5-sum.
md5File.sync(path: string) => string
Synchronously get the MD5-sum of the file at path
.
MIT