{"id":3613,"date":"2010-11-18T11:50:51","date_gmt":"2010-11-18T11:50:51","guid":{"rendered":""},"modified":"2026-04-18T22:52:48","modified_gmt":"2026-04-18T22:52:48","slug":"how-to-undelete-files-in-subversion","status":"publish","type":"post","link":"https:\/\/hellem.org\/wblog\/?p=3613","title":{"rendered":"How to undelete files in subversion"},"content":{"rendered":"<p>I accidentally deleted a bunch of directories using &#8220;svn delete&#8221; about a month ago, and now we realized that we needed them. So, question was &#8211; how to do undelete in Subversion since svn does not have a undelete-command. Then &#8216;svn copy -r REVISON&#8217; to the rescue. First attempt solution found at <a href=\"http:\/\/jappler.com\/blog\/archive\/2008\/05\/14\/undelete-something-with-svn\">jappler.com<\/a><\/p>\n<blockquote><p>\nsvn copy -r NUMBER NAMEOFDIRECTORY NAMEOFDIRECTORY\n<\/p><\/blockquote>\n<p>The above command resulted in &#8220;NAMEOFDIRECTORY not a working copy&#8221;&#8230;damn!!! But then I found a slightly different way of doing it at <a href=\"http:\/\/www.canfield.com\/content\/svn-restore-deleted-file\">www.canfield.com<\/a> and I did<\/p>\n<blockquote><p>\nsvn copy -r NUMBER https:\/\/{URL}\/NAMEOFDIRECTORY NAMEOFDIRECTORY\n<\/p><\/blockquote>\n<p>Success&#8230;and if you are unsure of your svn url, just type &#8216;svn info&#8217;<\/p>\n<p>Then to commit a list of folders in one operation I found the solution at <a href=\"http:\/\/stackoverflow.com\/questions\/236593\/svn-update-of-multiple-files\">Stackoverlow.com<\/a><\/p>\n<blockquote><p>\n cat mblade_list.txt | xargs svn commit -m &#8220;Restored&#8221;\n<\/p><\/blockquote>\n","protected":false},"excerpt":{"rendered":"<p>I accidentally deleted a bunch of directories using &#8220;svn delete&#8221; about a month ago, and now we realized that we needed them. So, question was &#8211; how to do undelete in Subversion since svn does not have a undelete-command. Then &#8216;svn copy -r REVISON&#8217; to the rescue. First attempt solution found at jappler.com svn copy [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[47],"tags":[],"class_list":["post-3613","post","type-post","status-publish","format-standard","hentry","category-work-geek"],"_links":{"self":[{"href":"https:\/\/hellem.org\/wblog\/index.php?rest_route=\/wp\/v2\/posts\/3613","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/hellem.org\/wblog\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/hellem.org\/wblog\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/hellem.org\/wblog\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/hellem.org\/wblog\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=3613"}],"version-history":[{"count":1,"href":"https:\/\/hellem.org\/wblog\/index.php?rest_route=\/wp\/v2\/posts\/3613\/revisions"}],"predecessor-version":[{"id":13996,"href":"https:\/\/hellem.org\/wblog\/index.php?rest_route=\/wp\/v2\/posts\/3613\/revisions\/13996"}],"wp:attachment":[{"href":"https:\/\/hellem.org\/wblog\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=3613"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/hellem.org\/wblog\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=3613"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/hellem.org\/wblog\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=3613"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}