Skip to content

gillstrom/capacity

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

capacity

Get your computers full charge capacity (OS X)

Full charge capacity refers to the amount of power as measured in mAh the battery is capable of containing. This number lowers as the battery becomes depleted with usage and age.

Apple's battery guarantee says:

Your battery is designed to retain up to 80% of its original capacity at 1000 complete charge cycles. The one-year warranty includes replacement coverage for a defective battery. Apple offers a battery replacement service for all MacBook, MacBook Air, and MacBook Pro notebooks with built-in batteries.

CLI

$ npm install --global capacity
$ capacity --help

  Usage
    $ capacity

Install

$ npm install --save capacity

Usage

const capacity = require('capacity');

capacity().then(value => {
	console.log(value);
	//=> 0.98
});

License

MIT © Andreas Gillström

About

Get your computers full charge capacity

Resources

License

Stars

Watchers

Forks

Packages

No packages published