wiki:Documentation/UserGuide/svnmerge

How to compare 2 versions of ORCHIDEE

Matt wrote:

There are times when you want to know what has changed between a version you are working on and a version someone else has in SVN. For example, someone told you about a cool feature in the OCN branch and you want to see how difficult it would be to put it into your personal copy. Such an action requires first to see how many differences there are between the version you are working on and the version of interest.

svn merge is a good way to do this. Let's say that I have my local copy of ORCHIDEE installed in modipsl/modeles/ORCHIDEE. Josefine has told me that she has a cool feature in her personal version that I might be interested in, so I'd like to know how many files are in conflict.

cd modipsl/modeles/
svn merge --dry-run svn://forge.ipsl.jussieu.fr/orchidee/perso/josefine.ghattas/.../ORCHIDEE ORCHIDEE

the "dry-run" option means that it will tell you what files are in conflict without actually doing the merge and changing your local version of the code.

The most important thing you need to know here is if you can actually access the version you are trying to merge with. If you go onto the Wiki under the Browse Source label (http://forge.ipsl.jussieu.fr/orchidee/browser), if you can see a version there when you are logged in, you should be able to access it. Be sure to find the location of the ORCHIDEE directory in the branch/personal folder that you are looking at. In the example above, Josefine might have several version of ORCHIDEE laying around, and therefore we needed to dive a little deeper to actually find the location of the ORCHIDEE folder.

Josefine wrote:

  • It is not easy to compare a local version from one branch (were local changes are not commited) with another branch.
  • You can easily compare
    • a local version(with changes that were not commited) with the same version on the SVN repository (the same branch). Use commands svn stat, svn -u stat, svn diff, etc. See also 10 minutes SVN and ORCHIDEE
    • 2 versions of ORCHIDEE on the SVN using the web interface. For example to compare branch DOFOCO with the trunk. Access the web-interface by using the bottom Browse source up to the right on this page. See also the end of document above.
Last modified 4 years ago Last modified on 12/02/14 17:43:39