SVN: Find and recover the directories/files that were mistakenly deleted

Source: Internet
Author: User
Tags commit svn tortoisesvn

This Monday found a very important library inside the Rel_tags directory is gone, quickly check the log. Find the following article, using the following methods:

1. In the local workingcopy, use Tortoisesvn->showlog to view the history of the repository. You can use search.
2. Find the deletion of the file or folder version, in LogMessage right-click Revertthechangesfromthisrevision.
3. The file or folder is restored to the local workingcopy. If it is deleted by mistake, commit to Repository in the line.

In this section we will learn about SVN delete files and their recovery problems, and share with you, welcome to study together, first let us look at the SVN delete files how to do, the following is the specific introduction.

SVN Delete file

First, local deletion
SVN delete a local delete in the file, refers to the client delete a file, but there is no commit, use revert to undo the deletion.

Second, server delete
1. Submit the server via local delete
A) Update the previous version, but only for the less modified cases;
b) through Showlog, find the deleted item, select, right-click->revertchangesfromthisrevision;

2. Delete in Repo-browser
This deletion is very bad, so that you can not see the deleted items in the Repo-browser. The fact that the project was not actually deleted.
A) Local projects still exist, click on the right button->tortoisesvn->updatetorevision, enter the deleted revision, OK, and then import up.
b) The local project is gone.
Right-click->tortoisesvn->export ...,
Urlofrepository fill in the address of the project;
Exportdirectory fill in the path to be backed up;
Revision, the default is Headrevision, but this is not available here. Since the project has been deleted, headrevision only works on existing projects, you'd better remember the previous version. If you really forget, look at it, until you find the version you need.
Click OK, if not the directory will prompt you to establish a, OK after the OK.

Recover svn Delete files or folders

With TortoiseSVN:
1. In the local workingcopy, use Tortoisesvn->showlog to view the history of the repository. You can use search.
2. Find the deletion of the file or folder version, in LogMessage right-click Revertthechangesfromthisrevision.
3. The file or folder is restored to the local workingcopy. If it is deleted by mistake, commit to Repository in the line.

With Eclipse's Subclipse plugin:
1. Use Team->showsvnrepositoryhistory to view the history of the repository.
2. Find the version that deleted the file or folder, and right-click Reverttoxxversion.
3. The file or folder is restored to the local workingcopy. If it is deleted by mistake, commit to Repository in the line. This section describes the SVN delete file and its recovery content.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.