Changes

Packages.xml

817 bytes added, 10:09, 18 August 2009
Actions: Added downgrade action, updated download action
==Actions==
Wpkg understands several actions: '''install''', '''upgrade''', '''downgrade''', '''remove''' and '''download'''. Multiple commands for each of these actions can be listed in the config file and wpkg will execute them in the order they are listed.
The '''install''' commands are executed by wpkg when a new package comes into scope for a profile.
The '''upgrade''' commands are executed when a new revision of a package comes into scope. That is, when the '''revision''' number in the '''packages.xml''' file on the server is larger than the one in the local '''wpkg.xml''' file. Note that the upgrade commands will be run even if the check conditions are already met.
 
The '''downgrade''' commands are executed if the version installed on the client is newer than the one on the server side.
The '''remove''' commands are executed when a package is removed from a profile.
The '''download''' commands are always executedwhen used on the global package leven. Since WPKG version 1.1.0 however, this command is also allowed as a sub-node of any of the other commands. This allows you to specify a download which is only downloaded for a specific command. This was implemented since it usually makes no sense to download the installation package again right before the remove commands are executed (which usually runs a local uninstall command which does not need the original installer). '''Note:''' If multiple install (or upgrade/downgrade/remove) commands are specified WPKG will download the the files of all command nodes of the same kind before starting to execute the commands in sequence.
In many of the examples in the [[:Category:Silent_Installers]] section, cmd.exe is executed to perform environment variable expansion and to use 'start /wait' to wait on the command being executed. This method of executing commands results in cmd windows appearing on screen. However, this method does not appear to be necessary. The current version of wpkg (0.9.10) executes commands using the WScript.Shell.Exec() function, which should expand environment variables. This isn't explicitly stated in the Microsoft SDK documentation, but seems to be the case. Wpkg then waits until the command is completed before continuing.
Anonymous user