The only sure method of getting rid of the tendency that I have found is one that Paul Bertholy recommended.
Take your normal stance with a ball on the ground and swing thru missing the ball completely on the inside a few times. After that go ahead and hit a few shots.
Also it is important to remember that shanks are only a half inch from being a perfect shot and less then a quarter inch from being a decent shot. The biggest problem with shanks is the fear and anguish that can be generated as result of hitting one.
Of course another solution is to get some clubs that are very difficult to shank. It is a mystery to me why so many name brand hybrid clubs have a bit of hosel on them that can hit the ball on an off center hit... I guess that the belief is that the offset is important for some reason. I really can't see it as it just makes the game more frustrating for the average golfer... A lot of shots off to the right for right handers are a result of hitting the hosel and are then responsible for a big pull on the next shot. The poor golfer has no idea what just happened to him... Just makes the game harder.