I have to automate the entire process of running scripts on automation device. Is it possible to get the udid of ios device and launch ios_webkit_debug_proxy using Java?
Here’s the shell script that i use. I trigger the shell script through java.Works fine.
#!/bin/bash -x
#Input variable
UDID=$(system_profiler SPUSBDataType | sed -n -E -e ‘/(iPhone|iPad)/,/Serial/s/ *Serial Number: *(.+)/\1/p’)
echo ‘Kill existing proxy’
killall -9 ios_webkit_debug_proxy
echo ‘Start New proxy for UDID:’$UDID
node /usr/local/lib/node_modules/appium/bin/ios-webkit-debug-proxy-launcher.js -c $UDID:27753