Skip to main content

Package Dependencies

Pre-install dependency checks (e.g., "needs .NET 8"). Default detection reads the uninstall registry under HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall or HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\Microsoft\Windows\CurrentVersion\Uninstall and matches DisplayName against namePattern, then compares DisplayVersionminVersion.

PropertyTypeRequiredDescription
displayNamestringyesFriendly name shown in the installer UI / log.
namePatternstringyesRegex matched against installed apps DisplayName.
minVersionstringnoMinimum acceptable version.
detectionScriptstringnoPath to a custom PowerShell script (overrides default detection). Receives $.name, $.displayName, $.minVersion, $.optional as args. Must return $true / $false.
installobjectnoIf supplied, the missing dependency is installed via WinGet. Only triggers in Full (/qf) and Reduced (/qr) UI modes.

install.winGet

PropertyTypeRequiredDefaultDescription
idstringyesWinGet package ID.
argumentsstringno--accept-source-agreements --disable-interactivity --force --exact --source wingetExtra winget install arguments.

Example

"msi": {
"packageDependencies": [
{
"displayName": "Microsoft Windows Desktop Runtime - 8.0.29 (x64)",
"namePattern": "^Microsoft Windows Desktop Runtime - .* \\(x64\\)$",
"minVersion": "8.0.0",
"install": {
"winGet": { "id": "Microsoft.DotNet.DesktopRuntime.8" }
}
},
{
"displayName": "Microsoft Visual C++ v14 Redistributable (x64) - 14.51.36247",
"namePattern": "^Microsoft Visual C\\+\\+ v\\d{2} Redistributable \\(x64\\) - .*",
"minVersion": "14.30.0",
"detectionScript": "ca\\detect-vcredist.ps1"
}
]
}

Bypassing dependency check

End users can pass MP_SKIPDEPCHECK=1 on the msiexec command line to bypass all dependency checks. Useful for environments where dependencies are pre-installed by other means.