Adding diff and revert functionalities.