Add device id to adb shell

TBR=kjellander

BUG=
TEST=
Review URL: https://webrtc-codereview.appspot.com/923005

git-svn-id: http://webrtc.googlecode.com/svn/trunk@2976 4adac7df-926f-26a2-2b94-8c16560cd09d
This commit is contained in:
leozwang@webrtc.org 2012-10-23 20:25:25 +00:00
parent 4828e4c61f
commit 6b1ed94922

View File

@ -15,7 +15,7 @@
adb_shell () {
local RET ADB_LOG
ADB_LOG=$(mktemp "${TMPDIR:-/tmp}/adb-XXXXXXXX")
adb shell "$@" ";" echo \$? | tee "$ADB_LOG"
adb "$1" shell "$@" ";" echo \$? | tee "$ADB_LOG"
sed -i -e 's![[:cntrl:]]!!g' "$ADB_LOG" # Remove \r.
RET=$(sed -e '$!d' "$ADB_LOG") # Last line contains status code.
rm -f "$ADB_LOG"