XCode 4 User Script

青春壹個敷衍的年華 提交于 2019-12-03 17:24:19

Yes, it seems like Apple dropped user script support :-( The only thing you can do is (from the Apple Developer Forum):

Your only option is to drop it in ~/Library/Scripts and then go to File > Services > Service Preferences... and set a keyboard shortcut.

This works, but is only an inferior replacement, since you won't have all the possibilities you used to have with Xcode user scripts in Xcode 3 :-(

Here is a post showing you how to create an Automator Action which you can use as a service in Xcode (via the service menu and assign a shortcut as mentioned above). I did that as well (modifying one of my scripts to read input from stdin and write output to stdout) and it works... as I said above, it is rather limited and it is ten times slower than it used to, but better than nothing.

I ran into this same issue and put together a wrapper script that allows Xcode 4 to run Xcode 3 user scripts.

It works by replacing the old style %%%{PBXFilePath}%%% variables in your scripts with values gleamed from Xcode 4 via AppleScript.

Its available on GitHub. https://bitly.com/HXHiij

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!