remove the old version of a file when downloading the newer version