aboutsummaryrefslogtreecommitdiffhomepage
path: root/platform_tools/android/bin/android_kill_skia
blob: 3c4a7573491e56eaa3c28991a8fe848d4cf987ab (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
#!/bin/bash
#
# android_kill_skia: kills any skia processes on the device.

SCRIPT_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"

SKIP_TOOLCHAIN_SETUP="true"
source $SCRIPT_DIR/android_setup.sh
source $SCRIPT_DIR/utils/setup_adb.sh

if [ $(uname) == "Linux" ]; then
    $ADB $DEVICE_SERIAL shell ps | grep skia | awk '{print $2}' | xargs -r $ADB $DEVICE_SERIAL shell kill
elif [ $(uname) == "Darwin" ]; then
    $ADB $DEVICE_SERIAL shell ps | grep skia | awk '{print $2}' | xargs $ADB $DEVICE_SERIAL shell kill
else
    echo "Could not automatically determine OS!"
    exit 1;
fi