examples | ||
lib | ||
tests | ||
.gitignore | ||
.preflight | ||
composer.json | ||
LICENSE | ||
phpunit.xml | ||
README.md |
linux/cpu
Installing using composer
Install from the command line:
$ composer require linux/cpu:0.1.*
Or add to your composer.json
:
"require": {
"linux/cpu": "0.1.*"
}
Using
use Linux\Cpu\Cpu;
$cpu = new Cpu();
$governors = $cpu->getAvailableGovernors();
$cpu->setGovernor("ondemand");
NOTE: You probably need to run the script using linux/cpu
as root, for example
using sudo
or su
.