Generate the .diff file and store it