Replace a bad habit with a better one. Instead of trying to "break out of a habit", try to use the trigger or cue to initiate a different action. Find something better, healthier, to replace the habit...