Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ability to revert a specific revision #47

Closed
GoogleCodeExporter opened this issue Mar 14, 2016 · 9 comments
Closed

ability to revert a specific revision #47

GoogleCodeExporter opened this issue Mar 14, 2016 · 9 comments

Comments

@GoogleCodeExporter
Copy link

A new feature request, ability to revert a specific revision from the
repository.

Thanks.

Original issue reported on code.google.com by ram...@gmail.com on 23 Jul 2009 at 11:47

@GoogleCodeExporter
Copy link
Author

I don't know what this means.

It is not possible to remove revisions from the repository.
It is already possible to revert changed files in a working copy.
It is already possible to update files in a working copy to any specific 
revision.

I welcome suggestions, but please be specific and explain what you mean.

Original comment by chris...@gmail.com on 23 Jul 2009 at 6:48

  • Added labels: Type-Enhancement
  • Removed labels: Type-Defect

@GoogleCodeExporter
Copy link
Author

let's say you made 20 commits with revision numbers 1000-1020, so your working 
copy
is at revision 1020, but you only and you want to revert changes made in 
revision 1010.

Original comment by ram...@gmail.com on 23 Jul 2009 at 7:02

@GoogleCodeExporter
Copy link
Author

You can't "revert" a change.  How would that work?
You can, however, already merge the change in reverse.
Try it.

Original comment by chris...@gmail.com on 23 Jul 2009 at 7:09

@GoogleCodeExporter
Copy link
Author

you can revert a change in your working copy, i am new to mac osx environment, 
but
this feature is used heavily in TortoiseSVN

http://tortoisesvn.net/docs/release/TortoiseSVN_en/tsvn-howto-rollback.html

check item number 3. Context Menu → Revert changes from this revision

Original comment by ram...@gmail.com on 23 Jul 2009 at 7:24

@GoogleCodeExporter
Copy link
Author

Their use of "revert" is not the save as Subversion's.
    "revert: Restore pristine working copy file (undo most local edits)."

Their use of "revert" means "reverse merge".  Read the line after the title 
"Use the merge dialog".
A reverse merge will TRY to undo a change.  It may leave a file in a Conflicted 
state.

In svnX you simply click the radio button of the revision log in the repository 
(to specify a revision) &
then drag the file or folder from the repository browser into the working copy 
window,
click Reverse Merge & then OK.

This is a first cut at the UI in svnX.  It will, undoubtedly, evolve.

Original comment by chris...@gmail.com on 23 Jul 2009 at 7:47

@GoogleCodeExporter
Copy link
Author

I believe the OP is asking about the following.  Suppose, for example, one's 
repo is this:

(revision 1) created a repository "foobar" with one file: foo
(revision 2) changed the file foo
(revision 3) changed foo again, at a different line

The OP wants to undo the changes committed at revision 2, but not lose the 
changes committed at revision 3, 
and do it in one command.  This would be the equivalent of something like 

svn update
svn diff -r2:1 > patchfile
patch < patchfile

but this doesn't work in general, since changes to a file in subsequent 
revisions may throw off line numbering 
cause the patch to fail.  But svn, knowing the entire revision history, could 
probably figure it out, in any case 
where subsequent revisions didn't disturb the specific changes one is trying to 
undo.  

Even this doesn't work:

svn update 
svn commit
svn diff -rHEAD:1  |patch
svn diff -r2:HEAD  |patch


Original comment by noo...@gmail.com on 4 Aug 2009 at 10:04

@GoogleCodeExporter
Copy link
Author

Yes, in windows envrionement we use TortoiseSVN we has never manage to fail us,
unfortunately we never manage to find something similar on the mac platform.

Original comment by ram...@gmail.com on 4 Aug 2009 at 10:11

@GoogleCodeExporter
Copy link
Author

It's probably not a good idea to use `svn diff ... | patch` in general.
Subversion has the merge command for this ...
which is why svnX provides merge support.
Does this not solve the issue?

A future version of svnX could also allow dragging directly from the 
repository's log to initiate a merge -
in which case svnX would then have to calculate/guess the URL.

Anyway, this _discussion_ should be moved to 
http://groups.google.com/group/svnx.

Original comment by chris...@gmail.com on 5 Aug 2009 at 12:00

@GoogleCodeExporter
Copy link
Author

Code committed in r135 now allows the user to initiate a (reverse) merge by 
dragging an entry from a Repository 
window's log view or a log entry's changed path into a Working Copy window.
The merge sheet is then displayed where the merge may be further customised.

Original comment by chris...@gmail.com on 14 Apr 2010 at 1:15

  • Changed state: Done

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant