Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Does svn have a `revert-all` command?

People also ask

How do you svn revert all?

If you want to undo all changes you made in a file since the last update you need to select the file, right click to pop up the context menu and then select the command TortoiseSVN → Revert A dialog will pop up showing you the files that you've changed and can revert. Select those you want to revert and click on OK.

Can we revert commit in svn?

To revert a single commit: Go to: Subversion -> Integrate Directory... Show activity on this post. Note that the svn merge command reverts a commit in the sense of having another commit undoing your changes, but keeping your wrong commit in the history.

How do I revert local changes in svn?

Right-click a file in the Current Folder browser and select Source Control > Revert using SVN. In the Revert Files dialog box, choose a revision to revert to. Select a revision to view information about the change such as the author, date, and log message. Click Revert.


You could do:

svn revert -R .

This will not delete any new file not under version control. But you can easily write a shell script to do that like:

for file in `svn status|grep "^ *?"|sed -e 's/^ *? *//'`; do rm $file ; done

There is a command

svn revert -R .

OR
you can use the --depth=infinity, which is actually same as above:

svn revert --depth=infinity 

svn revert is inherently dangerous, since its entire purpose is to throw away data—namely, your uncommitted changes. Once you've reverted, Subversion provides no way to get back those uncommitted changes


Use the recursive switch --recursive (-R)

svn revert -R .