Hi Carl,

On 20.07.2012 14:14, Carl van Eijk wrote:
I hope you can clarify for me. What's the difference between:

<commands>

    <command

        type="install"

        cmd='msiexec /i
        
"\\wbl-lon-util-1\wpkg\packages\Resources\Microsoft\SQL2008r2NativeClient\x64\sqlncli.msi"
        /qn IACCEPTSQLNCLILICENSETERMS=YES'>

    </command>

</commands>

This is "new style" WPKG command definition - somewhen introduced in WPKG 1.3 version. Older versions do not understand the <command /> tag.
Actually <command type="install" cmd=... /> is equal to <install cmd=.../>.
WPKG 1.3 still understands both types of command definition.

So you might ask why there are two ways to define an install command.
Actually with <command /> you can define any type. Just upgrade/downgrade/install/remove types are pre-defined. But feel free to define any other type. For example:
<command type="my-common-commands" cmd="..." />

Of course you can say that WPKG would never ever execute commands of type "my-common-commands" but you can include other commands as follows:

<command type="install" include="my-common-commands" />

This allows one to define a group of commands which do not have to be repeatedly defined as install/upgrade commands (often install/upgrade use the same commands and then need to add some type-specific actions) but rather include it.


<install cmd='msiexec /i
"\\wbl-lon-util-1\wpkg\packages\Resources\Microsoft\SQL2008r2NativeClient\x64\sqlncli.msi"
/qn IACCEPTSQLNCLILICENSETERMS=YES' />

As written above this is just legacy install command definition. The resulting actions WPKG performs will be identical to the use of <command .../> but provides a bit less flexibility.



or
<install cmd='msiexec /i
"\\wbl-lon-util-1\wpkg\packages\Resources\Microsoft\SQL2008r2NativeClient\x64\sqlncli.msi"
/qn IACCEPTSQLNCLILICENSETERMS=YES'>
</command>

This is syntactically incorrect and not well-formed XML. In your example the <install /> tag is not closed but there is a </command> closing tag which was never opened.

Although you might want to ask what is the difference between
<install cmd='msiexec ... /qn IACCEPTSQLNCLILICENSETERMS=YES' />
and
<install cmd='msiexec ... /qn IACCEPTSQLNCLILICENSETERMS=YES'></install>

The answer here would be: There is no difference. Both are valid XML and feel free to either close a tag immediately like "<tag />" at the end or specify an end tag like "<tag></tag>". This is just standard XML syntax.

br,
Rainer
-------------------------------------------------------------------------
wpkg-users mailing list archives >> http://lists.wpkg.org/pipermail/wpkg-users/
_______________________________________________
wpkg-users mailing list
wpkg-users@lists.wpkg.org
http://lists.wpkg.org/mailman/listinfo/wpkg-users

Reply via email to