Skip to content

Commit 03dcf75

Browse files
TravisEz13TrapGodBrim
authored andcommitted
Add sha256 hashes to release (PowerShell#16147)
* Add sha256 hashes to release * Update tools/releaseBuild/azureDevOps/templates/release-CreateGitHubDraft.yml
1 parent 1849662 commit 03dcf75

File tree

1 file changed

+11
-0
lines changed

1 file changed

+11
-0
lines changed

tools/releaseBuild/azureDevOps/templates/release-CreateGitHubDraft.yml

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,17 @@ steps:
1616
git clone https://$(AzureDevOpsPat)@mscodehub.visualstudio.com/PowerShellCore/_git/Internal-PowerShellTeam-Tools '$(Pipeline.Workspace)/tools'
1717
displayName: Clone Internal-Tools repository
1818

19+
- pwsh: |
20+
$Path = "$(System.ArtifactsDirectory)"
21+
$OutputPath = Join-Path $Path ‘hashes.sha256’
22+
$null = New-Item $OutputPath -ItemType File -Force
23+
foreach ($file in Get-ChildItem -Path $Path -File ){
24+
Get-FileHash -Algorithm SHA256 -Path $file |
25+
ForEach-Object { "$($_.Hash) *$($file.Name)" } |
26+
Out-File -Path $OutputPath -Append
27+
}
28+
displayName: Add sha256 hashes
29+
1930
- pwsh: |
2031
Import-module '$(Pipeline.Workspace)/tools/Scripts/GitHubRelease.psm1'
2132
Publish-ReleaseDraft -Tag '$(ReleaseTag)' -Name '$(ReleaseTag) Release of PowerShell' -Description '<-- Update Me -->' -User PowerShell -Repository PowerShell -PackageFolder $(System.ArtifactsDirectory) -Token $(GitHubReleasePat)

0 commit comments

Comments
 (0)