Skip to content

nsuite v2.2.1


nsuite / getFileMd5

Function: getFileMd5() ​

getFileMd5(options): Promise<string>

Defined in: UtilsFile.ts:197

Calculates the MD5 hash of a file and returns a promise that resolves with the hash.

Parameters ​

options ​

Pick<UnzipFileOptions, "pathFile">

The options for the hash operation.

Returns ​

Promise<string>

  • A promise that resolves with the MD5 hash of the file.

Example ​

ts
import { getFileMd5 } from "nsuite";
const md5 = await getFileMd5({ pathFile: "./package.json" });

Released under the Apache-2.0 License.