This is assuming the old cable is the new style rear entry.
Remove the drive, remove the plastic sleeve and guide inside the boat, pull shift slide out, remove clamp/tie on the shift cable bellow, using a 6 point 9/16 very deep socket unscrew shift cable.
For a front entry, cut the cable at the rear, using a deep socket unscrew cable , using the tool retap threads ,install new type cable