Use difflib instead of the diff program.