Patch Existing File Action

The Patch Existing File action allows you to compare the current version of a file with a previous existing file, generate a delta file as an update is being created, and then utilizing the delta file and the existing file to create the new file on deployed systems.  This action utilizes the Microsoft Delta Compression API to generate the patch file, and re-create the new file starting from the existing file.

 

Prepare Stage

During the prepare stage, this action verifies permissions to the target folder.

Execute Stage

During the execute stage, the original existing file is backed up in case the update must be rolled back.  The patch is then applied to the existing file.  After the patch is applied, the hash of the resulting file is compared to the hash of the target file that was taken when the update was created.  If the resulting file hash does not match, the action fails and a rollback is initiated.

Cleanup Stage

Removes the backup copies that were made during the execute stage.

Rollback Stage

Replaces the target file with the original back up created prior to performing the Execute stage.

 

 

Patch Existing File Action Editor

Action description – Descriptive text that can be used to identify this particular action in the Actions list.

 

Target client folder – The folder on the client to place files that contains the file(s) you are adding/replacing.

 

Subdirectories – The directory below the designated client root folder that contains the files.

 

Version Information displays the assembly version and file version of the baseline file and the target file.

 

The Patch Existing File action utilizes the Microsoft Delta Compression API to create a differential patch file between two versions of an assembly during an update build, and then packages the patch file into the update.

As the update is executed, this differential patch is combined with the base file that exists on a deployed client to construct the target file.

Utilizing the Patch Existing File action can significantly reduce the size of the resulting update package.  The specific version of the baseline file must be present on the system being updated.

 

NOTE: The Windows Installer SDK must be present on the system building the update package.  Get it here.  Patch extraction support is available on Windows 2000 and later.

 

See Also