just put your script in a file and run this file with 2> / dev / null at the end of the command line!
Thus, if there is a problem with the command, it will not stop your xcode assembly
In my case, I only ran the command to delete my previous copy of the application from the connected iphone, so it could give an error if the iphone does not exist. To solve this problem:
$ mobiledevice uninstall_app com.my.app 2>/dev/null
Saeed Badran Apr 09 '17 at 10:21 on 2017-04-09 10:21
source share