首页 > 代码库 > svn update -r m path 代码还原到某个版本

svn update -r m path 代码还原到某个版本

 

[root@ok 资料库]# svn log 简历 ------------------------------------------------------------------------r174 | svnroot | 2016-08-26 08:52:06 +0800 (Fri, 26 Aug 2016) | 1 line+12k------------------------------------------------------------------------r141 | svnroot | 2016-08-06 12:28:21 +0800 (Sat, 06 Aug 2016) | 1 line增加新的项目------------------------------------------------------------------------r140 | svnroot | 2016-08-06 12:18:18 +0800 (Sat, 06 Aug 2016) | 1 line增加换行------------------------------------------------------------------------r139 | svnroot | 2016-08-06 12:15:35 +0800 (Sat, 06 Aug 2016) | 1 line增加换行------------------------------------------------------------------------r138 | svnroot | 2016-08-06 11:01:06 +0800 (Sat, 06 Aug 2016) | 1 line删除最后一行------------------------------------------------------------------------r137 | svnroot | 2016-08-06 10:43:24 +0800 (Sat, 06 Aug 2016) | 1 linexg------------------------------------------------------------------------r136 | svnroot | 2016-08-06 10:42:24 +0800 (Sat, 06 Aug 2016) | 1 linexg------------------------------------------------------------------------r135 | svnroot | 2016-08-06 10:37:44 +0800 (Sat, 06 Aug 2016) | 1 line修改简历------------------------------------------------------------------------r134 | svnroot | 2016-08-06 10:33:14 +0800 (Sat, 06 Aug 2016) | 1 line------------------------------------------------------------------------
[root@ok 资料库]# cat 简历|head -n 1陈林 12k
[root@ok 资料库]# svn update -r 141 简历 U    简历Updated to revision 141.[root@ok 资料库]# cat 简历|head -n 1陈林[root@ok 资料库]# 

回滚后之前的版本消失了

[root@ok 资料库]# svn log 简历------------------------------------------------------------------------r141 | svnroot | 2016-08-06 12:28:21 +0800 (Sat, 06 Aug 2016) | 1 line增加新的项目------------------------------------------------------------------------r140 | svnroot | 2016-08-06 12:18:18 +0800 (Sat, 06 Aug 2016) | 1 line增加换行------------------------------------------------------------------------r139 | svnroot | 2016-08-06 12:15:35 +0800 (Sat, 06 Aug 2016) | 1 line增加换行------------------------------------------------------------------------r138 | svnroot | 2016-08-06 11:01:06 +0800 (Sat, 06 Aug 2016) | 1 line删除最后一行------------------------------------------------------------------------r137 | svnroot | 2016-08-06 10:43:24 +0800 (Sat, 06 Aug 2016) | 1 linexg------------------------------------------------------------------------r136 | svnroot | 2016-08-06 10:42:24 +0800 (Sat, 06 Aug 2016) | 1 linexg------------------------------------------------------------------------r135 | svnroot | 2016-08-06 10:37:44 +0800 (Sat, 06 Aug 2016) | 1 line修改简历------------------------------------------------------------------------r134 | svnroot | 2016-08-06 10:33:14 +0800 (Sat, 06 Aug 2016) | 1 line------------------------------------------------------------------------

 

svn update -r m path 代码还原到某个版本