1.0.2 • Published 5 years ago

file-count-custom v1.0.2

Weekly downloads
4
License
ISC
Repository
github
Last release
5 years ago

file-count-custom

Get your files size & counts in directory with specific extension.

Install

npm install file-count-custom

Usage

For specific extension.

const fileCountCustom = require('file-count-custom'):
let fileInfo = new fileCountCustom('/root', 'png').count();
console.log(fileInfo.count); // ex: 10
console.log(fileInfo.size);  // ex: 85.55 KiB

For all files.

const fileCountCustom = require('file-count-custom'):
let fileInfo = new fileCountCustom('/root').count();
console.log(fileInfo.count); // ex: 95
console.log(fileInfo.size);  // ex: 101.4 MB