Skip to content

Commit 416ca3e

Browse files
committed
Rename Microsoft.PowerShell.PSReadline.dll
To work around PowerShell Core not loading the dll from the same directory as PSReadLine.psd1, I've renamed the dll.
1 parent 217ab4f commit 416ca3e

10 files changed

+15
-15
lines changed

CheckHelp.ps1

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
param($Configuration = 'Release')
22

3-
$ourAssembly = "$PSScriptRoot\PSReadLine\bin\$Configuration\Microsoft.PowerShell.PSReadLine.dll"
3+
$ourAssembly = "$PSScriptRoot\PSReadLine\bin\$Configuration\Microsoft.PowerShell.PSReadLine2.dll"
44

55
$t ='Microsoft.PowerShell.PSConsoleReadLine' -as [type]
66
if ($null -ne $t -and $t.Assembly.Location -ne $ourAssembly)

GenerateFunctionHelp.ps1

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ param(
88

99
$errorActionPreference = "Stop"
1010

11-
$ourAssembly = "$PSScriptRoot\PSReadLine\bin\$Configuration\Microsoft.PowerShell.PSReadLine.dll"
11+
$ourAssembly = "$PSScriptRoot\PSReadLine\bin\$Configuration\Microsoft.PowerShell.PSReadLine2.dll"
1212

1313
$t ='Microsoft.PowerShell.PSConsoleReadLine' -as [type]
1414
if ($null -ne $t -and $t.Assembly.Location -ne $ourAssembly)

PSReadLine.build.ps1

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -69,20 +69,20 @@ task RestoreNugetPackages @restoreNugetParameters CheckNugetInstalled,{
6969

7070
$buildMamlParams = @{
7171
Inputs = { Get-ChildItem docs/*.md }
72-
Outputs = "$targetDir/en-US/Microsoft.PowerShell.PSReadLine.dll-help.xml"
72+
Outputs = "$targetDir/en-US/Microsoft.PowerShell.PSReadLine2.dll-help.xml"
7373
}
7474

7575
<#
7676
Synopsis: Generate maml help from markdown
7777
#>
7878
task BuildMamlHelp @buildMamlParams {
79-
platyPS\New-ExternalHelp docs -Force -OutputPath $targetDir/en-US/Microsoft.PowerShell.PSReadLine.dll-help.xml
79+
platyPS\New-ExternalHelp docs -Force -OutputPath $targetDir/en-US/Microsoft.PowerShell.PSReadLine2.dll-help.xml
8080
}
8181

8282
$buildAboutTopicParams = @{
8383
Inputs = {
8484
Get-ChildItem docs/about_PSReadLine.help.txt
85-
"PSReadLine/bin/$Configuration/Microsoft.PowerShell.PSReadLine.dll"
85+
"PSReadLine/bin/$Configuration/Microsoft.PowerShell.PSReadLine2.dll"
8686
"$PSScriptRoot/GenerateFunctionHelp.ps1"
8787
"$PSScriptRoot/CheckHelp.ps1"
8888
}
@@ -112,7 +112,7 @@ task BuildAboutTopic @buildAboutTopicParams {
112112

113113
$binaryModuleParams = @{
114114
Inputs = { Get-ChildItem PSReadLine/*.cs, PSReadLine/PSReadLine.csproj, PSReadLine/PSReadLineResources.resx }
115-
Outputs = "PSReadLine/bin/$Configuration/Microsoft.PowerShell.PSReadLine.dll"
115+
Outputs = "PSReadLine/bin/$Configuration/Microsoft.PowerShell.PSReadLine2.dll"
116116
}
117117

118118
<#
@@ -185,11 +185,11 @@ task LayoutModule BuildMainModule, BuildMamlHelp, {
185185
}
186186

187187

188-
Copy-Item PSReadLine/bin/$Configuration/Microsoft.PowerShell.PSReadLine.dll $targetDir
188+
Copy-Item PSReadLine/bin/$Configuration/Microsoft.PowerShell.PSReadLine2.dll $targetDir
189189
Copy-Item PSReadLine/bin/$Configuration/System.Runtime.InteropServices.RuntimeInformation.dll $targetDir
190190

191191
# Copy module manifest, but fix the version to match what we've specified in the binary module.
192-
$version = (Get-ChildItem -Path $targetDir/Microsoft.PowerShell.PSReadLine.dll).VersionInfo.FileVersion
192+
$version = (Get-ChildItem -Path $targetDir/Microsoft.PowerShell.PSReadLine2.dll).VersionInfo.FileVersion
193193
$moduleManifestContent = Get-Content -Path 'PSReadLine/PSReadLine.psd1' -Raw
194194
[regex]::Replace($moduleManifestContent, "ModuleVersion = '.*'", "ModuleVersion = '$version'") | Set-Content -Path $targetDir/PSReadLine.psd1
195195

PSReadLine/PSReadLine.csproj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
<ProjectGuid>{615788CB-1B9A-4B34-97B3-4608686E59CA}</ProjectGuid>
88
<OutputType>Library</OutputType>
99
<RootNamespace>Microsoft.PowerShell.PSReadLine</RootNamespace>
10-
<AssemblyName>Microsoft.PowerShell.PSReadLine</AssemblyName>
10+
<AssemblyName>Microsoft.PowerShell.PSReadLine2</AssemblyName>
1111
<TargetFrameworkVersion>v4.6.1</TargetFrameworkVersion>
1212
<FileAlignment>512</FileAlignment>
1313
<TargetFrameworkProfile>

PSReadLine/PSReadLine.psd1

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
@{
22
RootModule = 'PSReadLine.psm1'
3-
NestedModules = @("Microsoft.PowerShell.PSReadLine.dll")
3+
NestedModules = @("Microsoft.PowerShell.PSReadLine2.dll")
44
ModuleVersion = '2.0'
55
GUID = '5714753b-2afd-4492-a5fd-01d9e2cff8b5'
66
Author = 'Microsoft Corporation'

appveyor.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ before_build:
1111
build_script:
1212
- ps: |
1313
Invoke-Build -Task ZipRelease -Configuration Release
14-
platyPS\Get-HelpPreview .\bin\Release\PSReadLine\en-US\Microsoft.PowerShell.PSReadLine.dll-help.xml > .\bin\Release\PSReadLine.txt
14+
platyPS\Get-HelpPreview .\bin\Release\PSReadLine\en-US\Microsoft.PowerShell.PSReadLine2.dll-help.xml > .\bin\Release\PSReadLine.txt
1515
1616
artifacts:
1717
- path: .\bin\Release\PSReadLine.zip

docs/Get-PSReadLineKeyHandler.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
---
22
schema: 2.0.0
3-
external help file: Microsoft.PowerShell.PSReadLine.dll-help.xml
3+
external help file: Microsoft.PowerShell.PSReadLine2.dll-help.xml
44
---
55

66
# Get-PSReadLineKeyHandler

docs/Get-PSReadLineOption.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
---
22
schema: 2.0.0
3-
external help file: Microsoft.PowerShell.PSReadLine.dll-help.xml
3+
external help file: Microsoft.PowerShell.PSReadLine2.dll-help.xml
44
---
55

66
# Get-PSReadLineOption

docs/Set-PSReadLineKeyHandler.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
---
22
schema: 2.0.0
3-
external help file: Microsoft.PowerShell.PSReadLine.dll-help.xml
3+
external help file: Microsoft.PowerShell.PSReadLine2.dll-help.xml
44
---
55

66
# Set-PSReadLineKeyHandler

docs/Set-PSReadLineOption.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
---
22
schema: 2.0.0
3-
external help file: Microsoft.PowerShell.PSReadLine.dll-help.xml
3+
external help file: Microsoft.PowerShell.PSReadLine2.dll-help.xml
44
---
55

66
# Set-PSReadLineOption

0 commit comments

Comments
 (0)