Restore Android Samsung Galaxy S Captivate SGH-I896 back to original installation
I'd say use Kies to update your old one (or use Odin/Heimdall to install some firmware from here). Afaik the Galaxy S (Captivate) does not have a custom rom flash counter (that was introduced with the S2 to see if one had installed custom roms before, so you don't have to apply 'Triangle Away' to reset it before sending back your old phone)

You basically have 2 options for your new one:


Root the standard firmware using CF-Root by Chainfire
Install an aftermarket firmware like CyanogenMod (ICS already available, JB also)


To install CyanogenMod-9 (an Android-4.0/Ice-Cream-Sandwich based custom rom), here are some infos:
Here's their Wiki FAQ for your phone and here's the full update guide, here are downloads for the Captivate