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 DisplayVersion ≥ minVersion.
| Property | Type | Required | Description |
|---|---|---|---|
displayName | string | yes | Friendly name shown in the installer UI / log. |
namePattern | string | yes | Regex matched against installed apps DisplayName. |
minVersion | string | no | Minimum acceptable version. |
detectionScript | string | no | Path to a custom PowerShell script (overrides default detection). Receives $.name, $.displayName, $.minVersion, $.optional as args. Must return $true / $false. |
install | object | no | If supplied, the missing dependency is installed via WinGet. Only triggers in Full (/qf) and Reduced (/qr) UI modes. |
install.winGet
| Property | Type | Required | Default | Description |
|---|---|---|---|---|
id | string | yes | – | WinGet package ID. |
arguments | string | no | --accept-source-agreements --disable-interactivity --force --exact --source winget | Extra 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.