I have been struggling with RSI since late 2002. It is one of the scariest things you can never go through -- it really seems like the end of your career right there, on the spot.
Fortunately, it really can be dealt with successfully.
A lot of the answers given here are excellent, but in my opinion are rather standard. (Although, the answer that James gives is outstanding -- I would also adhere to his advice carefully. He's dead on.) The ergonomic modifications being suggested, such as a proper line of sight to the monitor, your posture when sitting, having your elbows at a 90° angle with the keyboard on your lap, etc., are all correct, and should be done, but are only the very beginning...
Again, all that advice should be followed, but I think most of this advice is being given by people who have not actually had RSI.
I will say, however, that with the correct adjustments, you can get past it, or at least survive pretty well with it.
My key advice, in order:
(1) See a doctor, if you have carpal tunnel syndrome, as opposed to a more general repetitive stress injury (RSI), then there is a simple surgery that can take care of this easily. Most people have a more generalized RSI, however, but this would be your first step, and worth checking out.
(2) Absolutely, positively, do not pass go, do not collect $200, and get yourself a Kinesis Keyboard. You do not have to get the most expensive version -- all the high-end macro support is probably a bit much for most people, but I would recommend that you get a keyboard where you can swap the keys. This allows you to use a Dvorak arrangement, or a modified/custom arrangement if you prefer. (My keyboard is fully customized this point.)
Changing to dvorak is a common
suggestion, however it doesn't doesn't
prevent pinky strain if you are an
avid user of modifier keys, such as
ctrl.
No, not true. Take a look at the Kinesis Keyboard. You will notice that a lot of the major keys are put on the thumb, including the alt and ctrl keys. This takes some getting used to, but is not very hard, and the thumb is a very strong digit, as opposed to the pinky, which is quite weak.
In addition, if you get a swappable keyboard, you can adjust some of the other keys: for example, I have customized mine to be similar to to the Dvorak arrangement (but not identical) and I have swapped the shift keys to be up one row -- along the same line as the home keys, instead of being out and down from the home-key line. This is an obvious adjustment, that all keyboard should do (except for the fact that it is nonstandard, and would drive people crazy at first). But for those with bad hands, reducing the travel distance for frequently used keys is critical.
(3) Trigger-point massage. If you buy books on RSI you will find that a lot of their advice involves trigger point massage along the arms, shoulders, upper neck, and back. But the key I found for me is to focus on the area below the elbows. Use a simple massage tool, or even something like a golf ball, to massage into your forearm. You will find where it hurts: press there and hold it. Slowly roll over the tight muscle and then back again, slowly. If you do this at night while watching TV, you will find it very easy to do, and your hands will be in much, much better shape next day. I am still shocked by how well this works.
(4) Voice recognition software. At first I thought this was absurd: you certainly cannot use voice recognition for programming. And you can't. However, you can use voice recognition for dictating e-mails, notes to yourself, etc. I even sometimes dictate my XML comments -- I type the occasional angle bracket myself, but otherwise you can dictate it directly. And you can certainly dictate forum replies -- I am dictating this one right now.
Voice recognition isn't perfect; this reply is error free only because I had to re-read through it from top to bottom to correct silly errors like "form" instead of "forearm" or the like. But dictating takes a huge amount of pressure off your hands, which is the key.
Voice recognition is built into Windows Vista, so it does not have to cost you a dime (if you have Vista). Dragon Naturally Speaking is $100-150, and is what I use. The voice recognition on Windows Vista is quite capable, but Dragon NaturallySpeaking 10.0 is even better, and it's worth the difference. [Update: The voice recognition on Windows 7 is even better and now is almost identical in capability to Dragon NaturallySpeaking. I would no longer pay for Dragon at this point. You can find speech recognition under Windows 7 by searching for "Windows Speech Recognition". -- MR]
(5) Change your mouse. Experiment with roller-balls, track pads, etc. Mice are relatively inexpensive (compared to keyboards, anyway) and can be rotated through: as you become sore with one mouse, swap it in for another type. You can also switch hands, if your mouse hand becomes too sore. (Yes, using a mouse with your wrong hand is more difficult, but is generally worth the switch is needed.) By rotating the mice I use, I have no problems.
So those are the key points: (1) see a doctor, (2) get yourself a Kinesis Keyboard, (3) trigger point massage, (4) voice-recognition software, and (5) change your mouse.
In addition, I would follow all the other advice involving ergonomics as to your chair, keyboard positioning, monitor height, etc. The are all worth doing, but I think that the five points that I have laid out are the most critical.
They have certainly been the most important ones for me.