From: Alexandre T. <kt...@fr...> - 2003-03-15 18:39:51
|
Le samedi, 15 mar 2003, =E0 14:25 Europe/Paris, Grzegorz Jakacki a =E9cri= t : >> I'm not expert at using Cvs and I see no command to do a rollback; =20 >> can you help? > > Wow, it is harder that I thougt (or maybe I am missing something). > This is what I came up with: > (1) Check out working copy > cvs co opencxx > cd opencxx > [sticky tag: none, sticky date: none] > (2) Use 'cvs log' on one of files that need rollback to > find out to what date you want to roll back. > [sticky tag: none, sticky date: none] > (3) Go back to the rollback date, e.g. > cvs update -D'2003/03/15 12:07:26 UTC' > WARNING: Remember to specify "UTC". 'cvs status' give you times in =20 > UTC, > but other commands accept date in your local time, unless you =20 > specify > UTC. > [sticky tag: none, sticky date: 2003.03.15.12.07.26] > (3) Tag the rollback point: > cvs tag sandbox_USERID_rollback_point Heck, does not work: verifytag: authorization of tag `sandbox_kthulhu_rollback_point' for =20 user `kthulhu' failed verifytag: please stick to these tag formats: verifytag: sandbox_kthulhu verifytag: sandbox_kthulhu_* verifytag: contact ja...@us... for more info verifytag: to change authorizations modify CVSROOT/verifytag cvs server: Pre-tag check failed > [sticky tag: none, sticky date: 2003.03.15.12.07.26] > (4) Get head revision in your working dir > cvs update -A > [sticky tag: none, sticky date: none] > (5) Branch out a sandbox > cvs tag -b sandbox_USERID_rollback_result > [sticky tag: none, sticky date: none] > (6) Switch to sandbox > cvs update -r sandbox_USERID_rollback_result > [sticky tag: sandbox_USERID_rollback_result, sticky date: none] > (7) Merge reversed changes from rollback point > to rollback result into rollback_result branch > cvs update \ > -jsandbox_USERID_rollback_result \ > -jsandbox_USERID_rollback_point > WARNING: Order of '-j' options is essential! > [sticky tag: sandbox_USERID_rollback_result, sticky date: none] > > (8) Commit rolled-back version to your sandbox branch > cvs commit > [sticky tag: sandbox_USERID_rollback_result, sticky date: none] > (9) Test branch 'sandbox_USERID_rollback_result' > or verify by other means, that you have > correct, compilable version in working dir > If you discover, that you rolled back to > wrong date: > (9.1) remove tags > cvs tag -d sandbox_USERID_rollback_point > cvs tag -d sandbox_USERID_rollback_result > (9.2) goto (1) and figure out proper date > (10) Update your working directory to head revision > cvs update -A > [sticky tag: none, sticky date: none] > (11) Merge the difference between rolled-back > revision and head into head > cvs update -jsandbox_USERID_rollback_result > [sticky tag: none, sticky date: none] > (12) Commit your changes > cvs commit -m 'rollback to 2003/03/15 12:07:26' > If you get "up-do-date check failed" it means > that someone is checking something at the same > time. Use webcvs or 'cvs status' to find out who > is it and contact him/her, because your rollback > will rollback his/her changes. > [sticky tag: none, sticky date: none] > (13) Rollback is complete, clean up (remove tags): > cvs rtag -d sandbox_USERID_rollback_point opencxx > cvs rtag -d sandbox_USERID_rollback_result opencxx Alex ------------------------------------------------------------------------=20 - Alexandre Tolmos E-mail:=A0...@fr... ICQ: 92964905 ------------------------------------------------------------------------=20 - "Ph'nglui mglw'nafh Cthulhu R'lyeh wgah'nagl fhtagn." ------------------------------------------------------------------------=20 - |