blob: a17f88d9736919289cb4e6bf2b832d81a2a849ee (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
|
#!/bin/bash
#
# android_kill_skia: kills any skia processes on the device.
SCRIPT_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
source $SCRIPT_DIR/utils/setup_adb.sh
SERIAL=""
while (( "$#" )); do
if [[ "$1" == "-s" ]];
then
if [[ $# -lt 2 ]];
then
echo "ERROR: missing serial number"
exit 1;
fi
SERIAL="-s $2"
shift
fi
shift
done
if [ $(uname) == "Linux" ]; then
$ADB $SERIAL shell ps | grep skia | awk '{print $2}' | xargs -r $ADB $SERIAL shell kill
elif [ $(uname) == "Darwin" ]; then
$ADB $SERIAL shell ps | grep skia | awk '{print $2}' | xargs $ADB $SERIAL shell kill
else
echo "Could not automatically determine OS!"
exit 1;
fi
|