Nice solution, got it to undo unzip as well
Pardon me for pulling up this old thread. This is still a top result searching 'undo tar'.
I successfully used the command construct posted by Infinity0. Life saver; I had over 3GB of files in my home directory while playing with a NWN install.
I also successfully tested and applied a modified version to undo unzip replacing the first part of the sequence with unzip -t file.zip.
Be aware that these can take a significant amount of processing power. If you have a number of files to do, consider combining them on one line with a semicolon as I have it below so that they execute in succession.
unzip -t /media/NW_DIAMOND/Data_linux.zip | sort -r | xargs rm -f 2>/dev/null;unzip -t /media/NW_DIAMOND/Data_Shared.zip | sort -r | xargs rmdir 2>/dev/null
Thanks LinuxQuestions.org community, thanks all.
Be real, be sober.