Subclipse on Fedora

Update 20110926: In Fedora 15, you can just install subversion-javahl-1.6.17-1.fc15 from Add/Remove Software tool, much easier than the method described earlier. :)

When trying to run Subclipse, I got the following error: Failed to load JavaHL Library. To get JavaHL loaded for Subclipse on Fedora, I had to first register on Collabnet before attempt to install JavaHL rpm from this location. Once installed, I had to run export LD_LIBRARY_PATH=/opt/CollabNet_Subversion/lib on the command line before running eclipse.

This above tip is the result of combining the howto from this and this page.

Using svn merge

I wanted to merge one revision I made in the trunk into one of the branches. So, I used Subversion’s svn merge command to accomplish this. Thanks to Ray M. for explained the Subversion merge command to me. Here are my notes:

Before I start, I identified the following information:

  • The target revision number in trunk that I wanted to merge into the branch. In this case, I assigned a revision number of 100.
  • The full URL for the trunk. I found this information by running svn info and looked for Repository Root. In my environment, the trunk is simply [Repository Root]/trunk.

With the above information, I was ready to do a dry-run to make sure the command produced the outcome I wanted. Here is what I ran:

cd [local branch directory]
svn merge -r99:100 --dry-run [Repository Root]/trunk

I basically changed directory into the branch where I want merge the trunk revision to. Next, I ran the svn command with the merge sub-command. For the revision numbers, I specified the revision I wanted to merge from the trunk as the second number and the first number was simply the second revision minus one. This essentially said to merge changes that happen between revision 99 and 100, which was equivalent to all the changes committed in revision 100. The URL to trunk told the merge sub-command where to look for the specified source revision number.

Once I was happy with the dry-out output, I ran the command again without the --dry-run option. This effectively merge revision 100 from trunk into the branch. Right after that, I ran svn diff to check if the diff output was what I expected before I commit the changes.