Package Exports
- diskusage-ng
- diskusage-ng/index.js
This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (diskusage-ng) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.
Readme
diskusage-ng - get disk usage info in pure JavaScript and without any dependencies
Supported operating systems:
- Windows (via WMIC)
- OSX/Linux/Posix (via df)
Usage
var diskusage = require('diskusage-ng');
diskusage('/home/me', function(err, usage) {
if (err) return console.log(err);
console.log(usage.total);
console.log(usage.used);
console.log(usage.available);
});
Commands
npm run testCredits
Thanks to @xiaoxiangmoe for providing TypeScript type definitions.
Thanks to @Congelli501 for replacing
child_process.execwithchild_process.execFileon POSIX systems making the code much more secure.Thanks to @mintaka-orionis for fixing long paths issue on POSIX systems.