Heat content and evolution of cometary nuclei