1. md5-file
Get the MD5-sum of a given file, with low memory usage, even on huge files.
md5-file
Package: md5-file
Created by: roryrjb
Last modified: Sun, 19 Jun 2022 17:15:17 GMT
Version: 5.0.0
License: MIT
Downloads: 5,399,066
Repository: https://github.com/roryrjb/md5-file

Install

npm install md5-file
yarn add md5-file

MD5 file

Get the MD5-sum of a given file, with low memory usage, even on huge files.

Installation

 npm install --save md5-file

Usage

As a module

 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}`)

As a command line tool

 $ md5-file LICENSE.md
ad1faf9381e43c471dc381c17a4ee4b6

API

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.

License

MIT

RELATED POST

Enhancing Vue.js Development: Harnessing the Potential of Vue-Loader

Enhancing Vue.js Development: Harnessing the Potential of Vue-Loader

Simplify Data Validation in Vue.js: A Step-by-Step Guide to Using Regex

Simplify Data Validation in Vue.js: A Step-by-Step Guide to Using Regex

Troubleshooting Made Easy: Common Issues and Solutions with vue-loader Without vue-cli

Troubleshooting Made Easy: Common Issues and Solutions with vue-loader Without vue-cli

Optimizing Webpack 4 with Vue CLI 3: Disabling the Cache-Loader

Optimizing Webpack 4 with Vue CLI 3: Disabling the Cache-Loader

Step-by-Step Guide: How to Add a Function to Your Vuex Plugin

Step-by-Step Guide: How to Add a Function to Your Vuex Plugin