I have been using svn:externals to bring the Zend Framework files into my project. This is what my svn:externals looks like:
-r 22731 http://framework.zend.com/svn/framework/standard/trunk/library/Zend/ Zend
-r 22731 http://framework.zend.com/svn/framework/extras/trunk/library/ZendX/ ZendX
I have it tied to revision 22731 which is the the revision of this repository path: http://framework.zend.com/svn/framework/standard/tags/release-1.10.7
I thought this was the preferred way to use externals, but when I look at the Zend_Version
class I notice that it says const VERSION = '1.11.0dev';
. Should I be doing svn:externals like this instead?
http://frame开发者_如何学Gowork.zend.com/svn/framework/standard/tags/release-1.10.7/library/Zend/ Zend
http://framework.zend.com/svn/framework/standard/tags/release-1.10.7/extras/library/ZendX/ ZendX
I do it the latter way, linking to a tagged version and it works great.
In fact, I believe Matthew Weier O'Phinney had a blog post recommending this approach. I'll look around for it and edit the answer if I find it.
UPDATE: Here's the MWOP post I mentioned. Interestingly, I remembered it incorrectly. In the comments, he identifies your method - point to a specific revision - as the absolutely foolproof method, noting that that it is possible, though extremely rare, for a tagged version to change.
The correct revision of the 1.10.7-Tag is 22830
and not 22731
. Just check your link.
I prefer to checkout my externals tagged. It is much more convenient to have a release version number than a long revisionnumber.
If I use tags I know it's a released (stable-)version.
Based on the feedback, a hybrid of the two seems like the best option:
-r 22731 http://framework.zend.com/svn/framework/standard/tags/release-1.10.7/library/Zend/ Zend
-r 22731 http://framework.zend.com/svn/framework/standard/tags/release-1.10.7/extras/library/ZendX/ ZendX
Here is my reasoning:
- Tags are designed for this purpose
- Released tags may have build-time changes not in the trunk
- Specifying the revision protects against changes introduced to the tag after code has been tested against it
You definetly SHOULD use the tag to checkout externals. There is no need to look for specific revision. That's what are tags made for ;)
精彩评论