This felt like a long time coming, but Rick was forced to kill his once best friend. On top of that, the undead version of Shane was eliminated by Carl in order to save Rick. Shane just wouldn't stay down.
You walk outside, you risk your life. You take a drink of water, you risk your life. Nowadays you breath and you risk your life. You don’t have a choice. The only thing you can choose is what you’re risking it for.