Skip to content

Commit

Permalink
Fixed an issue where ExcludeMultiTargets wasn't working as expected
Browse files Browse the repository at this point in the history
  • Loading branch information
Arlodotexe committed Dec 24, 2024
1 parent 5a12e3d commit eb7c442
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion MultiTarget/UseTargetFrameworks.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -39,13 +39,14 @@ $AllMultiTargets = @('wasm', 'uwp', 'wasdk', 'wpf', 'linuxgtk', 'macos', 'ios',
# Exclude as needed
foreach ($excluded in $ExcludeMultiTargets) {
$MultiTargets = $MultiTargets.Where({ $_ -ne $excluded });
$AllMultiTargets = $AllMultiTargets.Where({ $_ -ne $excluded });
}

Write-Output "Setting enabled MultiTargets: $MultiTargets"

# 'all' represents all available '$MultiTargets' values
if ($MultiTargets.Contains("all")) {
$enabledMultiTargets = @('$(AvailableMultiTargets)')
$enabledMultiTargets = $AllMultiTargets -join ";"
}
else {
$enabledMultiTargets = $AllMultiTargets.Where({ $MultiTargets.Contains($_) }) -join ";"
Expand Down

0 comments on commit eb7c442

Please sign in to comment.