Created
October 5, 2014 10:26
-
-
Save mrfabbri/9cd3e31c108cb10cc234 to your computer and use it in GitHub Desktop.
Starts and stops screen and audio (Mac) recording of an android attached device via adb
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
function stop_record() { | |
echo | |
echo "stopping audio recording" | |
cat << EOF | osascript -l AppleScript | |
tell application "Quicktime Player" | |
stop last item of (documents whose name contains "Audio Recording") | |
end tell | |
EOF | |
echo "pulling screen recording" | |
adb pull ./sdcard/my-movie.mp4; | |
exit; | |
} | |
trap stop_record SIGINT; | |
echo "starting audio recording" | |
cat << EOF | osascript -l AppleScript | |
tell application "Quicktime Player" | |
launch | |
start new audio recording | |
end tell | |
EOF | |
echo "starting screen recording" | |
adb shell screenrecord --verbose ./sdcard/my-movie.mp4; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment