When I type:
adb devices
My output is (this can be variable, it can list 10 or 20 etc):
List of devices attached
0280414640c133d7 device
TA054085R1 device
Afterwards I’d like to run:
adb install MyApp 0280414640c133d7
adb install MyApp TA054085R1
How can I get this going in a bash script?
I’m not sure how robust you need your solution to be, but something like this will work with the case you describe above:
It is no doubt possible to replace the ugly
egreppiped throughcutwith a single call tosedorawkor even aperlone-liner.