I use the following script to automatically start my executable Xcode project on an IOS device.
This script work fine on Xcode3, but on Xcode 4 it doesn't work normally , it report some error like can not get active project document
I execute the apple script like this
./debug Users:tom:network.xcodeproj
(This mean my project file is under Users/tom/network.xcodeproj with network.app under Users/tom/build/iPhoneDebug-iphoneos/network.app)
My script file is as follows
=========================Apple script Name : debug=======================
#!/usr/bin/osascript
##script for start executable from Xcode project, only debug mode could be used
on run argv
set myProject to (item 1 of argv)
tell application "Xcode"
open myProject
set targetProject to project of active project document
tell targetProject
try
with timeout of 10 seconds
debug targetProject
end timeout
end try
end tell
end tell
end run
Does anyone know why?? Or does anybody know how to debug an IOS app on Xcode4(on device) .