svn rollback

Sometimes I just wonder why there is no svn rollback… Well, this one should do it:

svn merge -rHEAD:NNNN rep-url working-copy

  • working-copy – path to your working copy.
  • rep-url – URL or path to your repository
  • NNNN – revision you want to rollback to

For instance this command below will merge rev. 2348 into your working copy:

svn merge -rHEAD:2348 svn+ssh://yourname@yoursvn.com/repository/path /home/yourname/project/yourproject

Don’t forget to commit after all conflicts are resolved.

Leave a Reply

Your email address will not be published. Required fields are marked *

*

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>