Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Currently when I unzip into a directory with pre-existing files, I sometimes unzip an archive to update the files, using -f or -u or -o to overwrite any clashes.

However I would like the unzip process to also delete any files which were not part of the archive, so that the unzipped version fully matches what was in the zipped archive. (Why not just replace the directory then with a fresh unzip? Because I still want to preserve .svn files, just wipe everything else)

share|improve this question
Well, if there is no .svn folder in the zip file, wouldn't such a process also remove the .svn folder? So, why not simply remove all folder contents except the .svn one?… – Oliver Salzburg Jun 25 '13 at 22:36

You must log in to answer this question.

Browse other questions tagged .