[Biopython-dev] Q: How to undo a CVS update ?

Andrew Dalke adalke at mindspring.com
Wed Sep 19 06:34:19 EDT 2001


Thomas of the Moving Turtle:
>Unfortunately I made an cvs update before comitting my local changes to
>generic.py ... :(
>
>Are there any hidden cvs commands to undo this stupid error ?

Don't know the official way to do that.  Here's what I do.

Suppose you want to revert to version 1.15

  rm filename.py
  cvs co -r1.15 filename.py
  mv filename.py filename.py.tmp
  cvs co filename.py
  rm filename.py
  mv filename.py.tmp filename.py
  cvs commit filename.py

The reason for the mv, co, rm, mv back is because the co with
a version number is sticky.  By moving it then checking out
the current version, I get rid of the sticky part.

There's documentation at http://www.cvshome.org/docs/

Huh.  How about
  http://www.cvshome.org/docs/manual/cvs_4.html#SEC53

] However, this isn't the easiest way, if you are asking
] how to undo a previous checkin (in this example, put
] `file1' back to the way it was as of revision 1.1). In
] that case you are better off using the `-j' option to
] update; for further discussion see 5.8 Merging differences
] between any two revisions.

and points to
 http://www.cvshome.org/docs/manual/cvs_5.html#SEC62

Try out the suggestion on that page.

And let me know if it works :)

                    Andrew
                    dalke at dalkescientific.com





More information about the Biopython-dev mailing list