3

被误用的svn checkout

 2 years ago
source link: https://www.lujun9972.win/blog/2018/06/07/%E8%A2%AB%E8%AF%AF%E7%94%A8%E7%9A%84svn-checkout/index.html
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.

被误用的svn checkout

最近写脚本,需要用SVN从服务器上下载某个文件下来。 由于对SVN不太熟悉,于是上网搜了一把,这一搜不要紧,把我吓了一大跳。 一堆的答案居然是用 svn checkout 来做的,而且由于 svn checkout 只能checkout一个目录,所有在checkout出目录后还需要把需要的文件从目录中拷贝出来...

问题是,我又不需要对这个下载下来的文件再进行版本控制,为什么要用 checkout 来实现呢?? 真正的做法应该是用 export 啊。 直接使用 svn export URL 就能把单个文件下载下来了。 唯一的问题在于这里的 URL 中不支持通配符。


About Joyk


Aggregate valuable and interesting links.
Joyk means Joy of geeK