Skip to content

Commit

Permalink
Update build script to always include the ProjectUri info (#3821)
Browse files Browse the repository at this point in the history
  • Loading branch information
daxian-dbw committed Apr 2, 2024
1 parent 3b21582 commit c78b7b1
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions PSReadLine.build.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -165,10 +165,14 @@ task LayoutModule BuildPolyfiller, BuildMainModule, {
if ($matches[1] -ne $version) { throw "AssemblyFileVersion mismatch with AssemblyInformationalVersion" }
$prerelease = $matches[2]

# Put the prerelease tag in private data
$moduleManifestContent = [regex]::Replace($moduleManifestContent, "}", "PrivateData = @{ PSData = @{ Prerelease = '$prerelease'; ProjectUri = 'https://github.com/PowerShell/PSReadLine' } }$([System.Environment]::Newline)}")
# Put the prerelease tag in private data, along with the project URI.
$privateDataSection = "PrivateData = @{ PSData = @{ Prerelease = '$prerelease'; ProjectUri = 'https://github.com/PowerShell/PSReadLine' } }"
} else {
# Put the project URI in private data.
$privateDataSection = "PrivateData = @{ PSData = @{ ProjectUri = 'https://github.com/PowerShell/PSReadLine' } }"
}

$moduleManifestContent = [regex]::Replace($moduleManifestContent, "}", "${privateDataSection}$([System.Environment]::Newline)}")
$moduleManifestContent = [regex]::Replace($moduleManifestContent, "ModuleVersion = '.*'", "ModuleVersion = '$version'")
$moduleManifestContent | Set-Content -Path $targetDir/PSReadLine.psd1

Expand Down

0 comments on commit c78b7b1

Please sign in to comment.