15

如何通过HTTP协议访问指定版本的SVN库内容 - 暗无天日

 3 years ago
source link: https://www.lujun9972.win/blog/2020/06/20/%E5%A6%82%E4%BD%95%E9%80%9A%E8%BF%87http%E5%8D%8F%E8%AE%AE%E8%AE%BF%E9%97%AE%E6%8C%87%E5%AE%9A%E7%89%88%E6%9C%AC%E7%9A%84svn%E5%BA%93%E5%86%85%E5%AE%B9/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.

如何通过HTTP协议访问指定版本的SVN库内容 - 暗无天日

如何通过HTTP协议访问指定版本的SVN库内容

在汇总晨检报告时,有同事反馈提交的内容被覆盖了,需要从某个指定版本中取出被覆盖的内容。 然而我在跳板机上只能通过HTTP协议用浏览器访问SVN仓库,默认访问的是最新版本内容。

那么要如何通过HTTP协议访问指定版本的内容呢?经过一番搜索,在 http://beerpla.net/2010/02/20/how-to-view-a-specific-svn-revision-in-your-browser/ 找到了解决方法,于是想着记录下来。

方法其实很简单,就是在URL的仓库根后面加上 /!svn/bc/版本号/ 即可。

比如,我们想要看 https://plugins.svn.wordpress.org/stats/trunk/readme.txt 的 100000 版本的内容,我们可以这么做:

所以访问路径 https://plugins.svn.wordpress.org/!svn/bc/100000/stats/trunk/readme.txt 即可。

另外,若 SVN 版本操作1.6,还可以通过在 URL 后添加 ?p=版本号, 也即访问 https://plugins.svn.wordpress.org/stats/trunk/readme.txt?p=100000 也能起到相同的作用。

2020-06-20 2020-06-20 linux和它的小伙伴 lujun9972

About Joyk


Aggregate valuable and interesting links.
Joyk means Joy of geeK