I thought there was a way to test your applications in development over Wi-Fi. Is this possible?
I\'d love to be able to untether my phone and develop wirelessly.
Though there are so many good answers, here is my two cents for the future me :P and for anyone who wants it quick and easy.
For Mac:
open terminal and run the following script
adb tcpip 5555
adb connect $(adb shell ifconfig | grep "inet " | grep -v 127.0.0.1 | awk '{print $2}' | cut -d: -f2):5555
Explanation:
adb tcpip 5555
commands the device to start listening for connections on port 5555
adb connect $(_ip_address_fetched_):5555
tells to connect on port 5555 of the _ip_address_fetched_
address
where _ip_address_fetched_
includes following:
adb shell ifconfig
getting internet configurations using adb shell
grep "inter "
filter any line that starts with inter
grep -v 127.0.0.1
exclude localhost.
At this point, output should be like:
inet addr:###.###.#.### Bcast:###.###.#.### Mask:255.255.255.0
awk '{print $2}'
get the second part of the components array, separated by space (I'm using zsh).
The output up to this point is
addr:###.###.#.###
cut -d: -f2
split the string by delimiter : and take second part. It will only take your device IP address