How to Add Those @2x iOS5 Resources to SVN

{}} {}} {}}

In order for your app to take full advantage of the iPhone 4 Retina Display, you'll need to add 2x resources to your iPhone project.

If you're using SVN to manage your files, you'll be faced with something pretty annoying:

$ svn add xunYi7/library/images/blackArrow@2x.png
svn: warning: 'xunYi7/library/images/blackArrow' not found

This was incredibly frustrating for me, no matter how I tried to escape it: single quotes, double quotes, backslashes, etc. SVN refused to add.

This is due to internal path recognizers in SVN. It expects the last at symbol to specify a revision. This is easily corrected by adding an at symbol to the end of your file:

$ svn add xunYi7/library/images/blackArrow@2x.png@
A  (bin)  xunYi7/library/images/blackArrow@2x.png

You'll still need to manually add each resource, but it's better than nothing. You could also use an IDE like Cornerstone, but I prefer the SVN CLI way of managing SVN.



davidzhang 创作并维护的 Gowhich 博客采用 创作共用保留署名-非商业-禁止演绎4.0国际许可证。

本文首发于 Gowhich 博客( ),版权所有,侵权必究。


comments powered by Disqus