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/bash | |
# Step 1: Get phone's IP address | |
echo "Finding phone's IP address..." | |
PHONE_IP=$(adb shell ip route | awk '{print $9}') | |
# Check if IP address was found | |
if [ -z "$PHONE_IP" ]; then | |
echo "Could not find the phone's IP address. Make sure your phone is connected via USB and USB debugging is enabled." | |
exit 1 |