Changes

Jump to: navigation, search

Extended host attribute matching

1,022 bytes added, 01:11, 11 January 2014
added an architecture variable to simplify packages
<variable name="PKG_DEST" value="%ProgramFiles%\Mozilla Firefox" architecture="x86"/>
<variable name="PKG_DEST" value="%ProgramFiles(x86)%\Mozilla Firefox" architecture="x64"/>
</source>
 
If you are creative with your usage of variables then you can use them to dramatically simplify your packages.
 
'''Simplify you packages:'''
<source lang="xml">
<!-- set destination folder based on architecture -->
<variable architecture="x86" name="PROGFILES" value="%PROGRAMFILES%" />
<variable architecture="x64" name="PROGFILES" value="%PROGRAMFILES(X86)%" />
 
<!-- BEFORE -->
<check type="logical" condition="or">
<check type="file" architecture="x86" condition="versiongreaterorequal" path="%PROGRAMFILES%\Common Files\microsoft shared\OFFICE15\MSO.DLL" value="15.0.4420.1017" />
<check type="file" architecture="x64" condition="versiongreaterorequal" path="%PROGRAMFILES(X86)%\Common Files\microsoft shared\OFFICE15\MSO.DLL" value="15.0.4420.1017" />
</check>
 
<!-- AFTER --> <!-- Now you don't have to use a conditional check statement!!! -->
<check type="file" condition="versiongreaterorequal" path="%PROGFILES%\Common Files\microsoft shared\OFFICE15\MSO.DLL" value="15.0.4420.1017" />
 
</source>
Anonymous user

Navigation menu