Updating deletes executable

I've observed an issue with using wyBuild with my winform. What i'm observing is that updating from one version to the next will delete my app.exe after the update.

Here's what I do:AutomaticUpdater.dll v2.6.11.2wyUpdate.exe v2.6.11.3

I'm testing out some updates going from v0.2.9 to v0.2.10In v0.2.9 I've included AutomaticUpdater.dll and my app.exeIn v0.2.10, I've only included app.exe without the automaticupdater dll.I've also made client.wyc for both versions 0.2.9 and 0.2.10And uploaded all updating paths to the server.

Then I artificially copy over the v0.2.9 app.exe and client.wyc and kick off my app.exeMy app.exe has this logic:

Process proc = new Process { StartInfo = { FileName = "wyUpdate.exe", Arguments = "-quickcheck -justcheck -noerr" } }; proc.Start(); proc.WaitForExit(); if (proc.ExitCode != 2) { Application.Run(new Form1()); } else { Process.Start("wyUpdate.exe"); Application.Exit(); }

So all that it does is kick off the wyupdate if a update is found. otherwise it will start the app.

When I kick off the app.exe, it goes through and updates to 0.2.10 and then at the end of the update, after i click finish, the app.exe disappears.

The first time i noticed this is when i created v0.2.10 with no files to update. So an empty update. When i updated to the empty update, both automaticupdater.dll and app.exe disappeared after the update.

As a workaround when i create v0.2.10, i include both automaticupdater and app.exe, the update works as expected. app.exe is updated, automaticupdater remains on v2.6.11.2.

EDIT:I've had a bit more play around, the behaviour that I can reproduce is this. Any file that is not in the update that used to be part of the update in a previous version is deleted. This sounds like a preference option or logical error or design decision?Is there anyway that my updates can be non-subtractive? Or that I can specify which files to delete if any.

wyBuild compares version of your app and makes a note of the necessary changes to go from "version X" to "version Y". So if you include all files in "version X" and you leave "version Y" empty, then wyBuild will read this as "delete all files that were in "version X" but are not in "version Y".

Short answer: Include all files from all versions of your app -- wyBuild will take care of comparing the versions and generating the smallest possible patch.