开发者

svn copy -r [revision number] [url] [path]

开发者 https://www.devze.com 2023-03-17 19:22 出处:网络
So, I\'ve done this before and I just can\'t seem to figure out what\'s broken this time... I\'m trying to restore a file from SVN. I w开发者_如何学JAVAent and found the revision where it was deleted

So, I've done this before and I just can't seem to figure out what's broken this time...

I'm trying to restore a file from SVN. I w开发者_如何学JAVAent and found the revision where it was deleted (or at least last existed. I verified by using svn list -r)

Here is my command:

svn copy -r 925 url/to/repo/foldername htdocs/foldername

I keep getting an error:

svn: '/!svn/bc/973/.../htdocs/templates' path not found

From my understanding that means its looking in revision 973 (which is HEAD) instead of 925.

What am I missing here?


I think what you want is:

svn copy url/to/repo/foldername@925 htdocs/foldername

From svn help copy:

usage: copy SRC[@REV]... DST

See Peg and Operative Revisions.

Using -r REV without @REV means "the ancestor (revision REV) of the current file" while @REV without -r rev means "the file at REV". This semantic difference is significant because svn tracks copies (and renames).

0

精彩评论

暂无评论...
验证码 换一张
取 消