iwtbauh
2018-04-23 08:33:25 +08:00
有 root 可以用这个命令
(做成脚本,用终端模拟器创建桌面图标一键执行脚本)
am start: start an Activity. Options are:
-D: enable debugging
-N: enable native debugging
-W: wait for launch to complete
--start-profiler <FILE>: start profiler and send results to <FILE>
--sampling INTERVAL: use sample profiling with INTERVAL microseconds
between samples (use with --start-profiler)
-P <FILE>: like above, but profiling stops when app goes idle
-R: repeat the activity launch <COUNT> times. Prior to each repeat,
the top activity will be finished.
-S: force stop the target app before starting the activity
--track-allocation: enable tracking of object allocations
--user <USER_ID> | current: Specify which user to run as; if not
specified then run as the current user.
--stack <STACK_ID>: Specify into which stack should the activity be put.
am startservice: start a Service. Options are:
--user <USER_ID> | current: Specify which user to run as; if not
specified then run as the current user.
# am start 包名 /.活动名