![]() |
Batch file to delete only installed files
Hello all, I'm a little lazy to make a Wiki account at the moment, but I have something here that others might find useful. I'm about to remove it from my HDD, so I thought I'd first post it here for others to use.
------- Here is a windows batch file that is useful for making an uninstaller only delete the files that were added by the installer: code: Here is how to use it: -You need to have one big folder that you are installing via the 'file' instruction, including all files and subfolders. The outdir for this file must be the instdir. Let's say it is C:\myprogram. -Place the batch file in the parent folder (in our example it would be C:\). -Find/replace all of the words PROJECT in the above code, with the name of the folder to be processed (in our example it would be myprogram). -Run the batch file. It will create a file called "uninstall_files.nsh". -!include this file in the uninstall section of your .nsi file. ------- Basically, the created .nsh file has a list of 'delete' instructions to delete all files added by the installer. Then it has a bunch of 'rmdir' instructions, to remove all directories, if they are empty. It is simple, ugly and inelegant, but it works. Enjoy! |
I use UnList.exe and it works fine. Described here: http://forums.winamp.com/showthread.php?postid=1862656
|
You don't need a Wiki account to share. Anyone can create a page.
|
| All times are GMT. The time now is 05:16. |
Copyright © 1999 - 2010 Nullsoft. All Rights Reserved.