David Brown wrote:
> On Sun, Jul 20, 2008 at 12:13:25AM -0700, Tracy R Reed wrote:
> 
>>> How simple is it?  Is there a single command to back out changes, or
>>> does
>>
>> There is indeed a single command: svn revert
> 
> As far as I can tell from the docs, 'svn revert' merely puts the files back
> to the state they were last in in the repo.  This would be equivalent to
> 'git reset'.
> 
> What I'm talking about is committing a set of changes, then later,
> possibly many commits later, issuing another command that undoes the
> earlier commit.
> 
> For example.  I remove a block of code and commit the change.  Later, we
> decide we need the block of code back:
> 
>   git revert commit-id
> 
> using the ID for the change that removed the block of code will create a
> new commit that puts the block of code back in.
> 
> I think this can be done with 'svn merge', but you'd have to figure out
> what files are involved and which versions to specify by yourself.

I have used something like the following to apply a change from "trunk"
to a working version (in a different branch):
  svn merge -r 10469:10471
    https://proj.svn.sourceforge.net/svnroot/proj/trunk

..which I thought was simple enough -- after laboring to decipher the
manual/help. I don't know if others have as much difficulty as I do, but
I sure wish these docs had more examples illustrating command formats.

..Oh well..

To back-out changes spanning those 2 commits 10470 and 10471, I think
the command might possibly be
  svn merge -r 10471:10469
    https://proj.svn.sourceforge.net/svnroot/proj/trunk

> 
> This kind of thing is somewhat of a chicken-and-egg problem.  People don't
> think of backing out older changes because their VCS doesn't do it easily,
> and the VCSes don't do it because they ask users, and the users don't think
> they need it.  There are a lot of very useful things that can be easily
> done once you have all of your history around.
> 

Regards,
..jim


-- 
[email protected]
http://www.kernel-panic.org/cgi-bin/mailman/listinfo/kplug-list

Reply via email to