8种机械键盘轴体对比
本人程序员,要买一个写代码的键盘,请问红轴和茶轴怎么选?
简介:Battery historian是一款通过上传bugreport文件分析用户手机中App的电池耗电情况的工具。
搭建battery-historian安装JDK
安装Python
安装Go语言配置GOROOT和GOPATHGOROOT:Go的安装根目录
GOPATH:Go的工程目录
配置环境变量把Go的bin目录路径加入Path
go version
安装git
下载源码
打开git bash:
[email protected] MINGW64 ~
$ go get -d -u github.com/google/battery-historian/...
找到battery-historian的git目录
[email protected] MINGW64 /e/WorkSpace/GoWorkSpace/src/github.com/google/battery-historian (master)
$ pwd
/e/WorkSpace/GoWorkSpace/src/github.com/google/battery-historian
下载:
[email protected] MINGW64 /e/WorkSpace/GoWorkSpace/src/github.com/google/battery-historian (master)
$ go run setup.go
Downloading Closure library...
Downloading Closure compiler...
Downloading 3rd-party JS files...
Generating JS runfiles...
Generating optimized JS runfiles...
启动: go run cmd/battery-historian/battery-historian.go
[email protected] MINGW64 /e/WorkSpace/GoWorkSpace/src/github.com/google/battery-historian (master)
$ go run cmd/battery-historian/battery-historian.go
2017/02/21 14:00:54 Listening on port: 9999
2017/02/21 14:00:59 Trace starting analysisServer processing for: GET
2017/02/21 14:00:59 Trace finished analysisServer processing for: GET
浏览器打开http:localhost:9999
电量测试
运行 adb bugreport
连接手机,运行命令:adb bugreport > C:Usersxxxxbugreport.txt
进行操作手机App等,运行一段时间后(看自己的运行场景而定),结束上面的命令(Ctrl + C).
上传bugreport.txt文件
把得到的bugreport.txt上传到battery-historian,结果如下:
官网文档:https://github.com/google/battery-historian