Skip to content

Instantly share code, notes, and snippets.

@jsonfry
Created August 15, 2016 10:13
Show Gist options
  • Save jsonfry/c49d3f5ff680d8fe80131782e0e6a32f to your computer and use it in GitHub Desktop.
Save jsonfry/c49d3f5ff680d8fe80131782e0e6a32f to your computer and use it in GitHub Desktop.
quick way to get a screenshot from an Android device onto my Mac
#! /bin/bash
timestamp=$(date +"%Y-%m-%d_%H-%M-%S")
adb shell screencap -p /sdcard/$timestamp.png
adb pull /sdcard/$timestamp.png ~/Desktop/$timestamp.png
adb shell rm /sdcard/$timestamp.png
@jsonfry
Copy link
Author

jsonfry commented Aug 15, 2016

Put this in /usr/local/bin and chmod +x it if you’d like to use it too 🙂

Then you can just adbss to get a screenshot on your desktop!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment