Firstly, it was not 'thieving' it was armed robbery and assault. It's absolutely possible the shopkeeper could have died from the attack; men have died from much less after all. Most courts recognise that as being far more serious than petty theft. So although it may not count as a 'capital crime' in your view, most people would consider it to be pretty heinous.
Secondly, why should the offender HAVE the chance for rehabilitation? He is a violent offender, what value does he have to society? The cost to rehabilitate him will almost certainly outweigh any potential value he can return to society. Just string the swine up for the crows.