1919 [ValidateSet (" Debug" , " Release" )]
2020 [string ]$Configuration = (property Configuration Release),
2121
22- [ValidateSet (" net461 " , " net6.0" )]
22+ [ValidateSet (" net462 " , " net6.0" )]
2323 [string ]$Framework ,
2424
2525 [switch ]$CheckHelpContent
@@ -32,7 +32,7 @@ $targetDir = "bin/$Configuration/PSReadLine"
3232
3333if (-not $Framework )
3434{
35- $Framework = if ($PSVersionTable.PSEdition -eq " Core" ) { " net6.0" } else { " net461 " }
35+ $Framework = if ($PSVersionTable.PSEdition -eq " Core" ) { " net6.0" } else { " net462 " }
3636}
3737
3838Write-Verbose " Building for '$Framework '" - Verbose
@@ -64,9 +64,9 @@ $mockPSConsoleParams = @{
6464<#
6565Synopsis: Build the Polyfiller assembly
6666#>
67- task BuildPolyfiller @polyFillerParams - If ($Framework -eq " net461 " ) {
68- # # Build both "net461 " and "net6.0"
69- exec { dotnet publish -f " net461 " - c $Configuration Polyfill }
67+ task BuildPolyfiller @polyFillerParams - If ($Framework -eq " net462 " ) {
68+ # # Build both "net462 " and "net6.0"
69+ exec { dotnet publish -f " net462 " - c $Configuration Polyfill }
7070 exec { dotnet publish -f " net6.0" - c $Configuration Polyfill }
7171}
7272
@@ -128,15 +128,15 @@ task LayoutModule BuildPolyfiller, BuildMainModule, {
128128 Set-Content - Path (Join-Path $targetDir (Split-Path $file - Leaf)) - Value (ConvertTo-CRLF $content ) - Force
129129 }
130130
131- if ($Framework -eq " net461 " ) {
132- if (-not (Test-Path " $targetDir /net461 " )) {
133- New-Item " $targetDir /net461 " - ItemType Directory - Force > $null
131+ if ($Framework -eq " net462 " ) {
132+ if (-not (Test-Path " $targetDir /net462 " )) {
133+ New-Item " $targetDir /net462 " - ItemType Directory - Force > $null
134134 }
135135 if (-not (Test-Path " $targetDir /net6plus" )) {
136136 New-Item " $targetDir /net6plus" - ItemType Directory - Force > $null
137137 }
138138
139- Copy-Item " Polyfill/bin/$Configuration /net461 /Microsoft.PowerShell.PSReadLine.Polyfiller.dll" " $targetDir /net461 " - Force
139+ Copy-Item " Polyfill/bin/$Configuration /net462 /Microsoft.PowerShell.PSReadLine.Polyfiller.dll" " $targetDir /net462 " - Force
140140 Copy-Item " Polyfill/bin/$Configuration /net6.0/Microsoft.PowerShell.PSReadLine.Polyfiller.dll" " $targetDir /net6plus" - Force
141141 }
142142
0 commit comments