Skip to content

Commit

Permalink
remove conflicting font check
Browse files Browse the repository at this point in the history
  • Loading branch information
jpawlowski committed Aug 27, 2024
1 parent c0f2557 commit b93da32
Showing 1 changed file with 1 addition and 11 deletions.
12 changes: 1 addition & 11 deletions src/powershell-extended/Install-NerdFont.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -556,17 +556,7 @@ begin {
}

if ($invalidSelections.Count -eq 0) {
# Check for conflicting fonts
$conflictingFonts = $validSelections | Group-Object -Property unpatchedName | Where-Object { $_.Count -gt 1 }
if ($conflictingFonts.Count -eq 0) {
return $validSelections.caskName
}
else {
foreach ($conflict in $conflictingFonts) {
$conflictNames = $conflict.Group | ForEach-Object { $_.imagePreviewFont }
Write-Host "Conflicting selection(s): $($conflictNames -join ', '). These fonts cannot be installed together because they share the same base font name." -ForegroundColor Red
}
}
return $validSelections.caskName
}
else {
Write-Host "Invalid selection(s): $($invalidSelections -join ', '). Please enter valid numbers between 0 and $($Options.Length - 1) or 'q' to quit." -ForegroundColor Red
Expand Down

0 comments on commit b93da32

Please sign in to comment.