If, on retreat, you constantly dwell on past nonvirtuous actions and feel miserable because of it, it might help to switch methods and repeat, "I've done bad things, I've done bad things." In this way you can change self-indulgence into right concentration. If you cannot do this, then you will be burdened and distracted by your thoughts, and you will be unable to continue practicing.

Master Sheng-yen, Complete Enlightenment