Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 7 additions & 3 deletions tools/packaging/packaging.psm1
Original file line number Diff line number Diff line change
Expand Up @@ -2204,10 +2204,14 @@ function New-ReferenceAssembly

$sourceProjectRoot = Join-Path $PSScriptRoot "projects/reference/$assemblyName"
$sourceProjectFile = Join-Path $sourceProjectRoot "$assemblyName.csproj"
Copy-Item -Path $sourceProjectFile -Destination "$projectFolder/$assemblyName.csproj" -Force
Copy-Item -Path (Join-Path -Path $PSScriptRoot -ChildPath "../../nuget.config") -Destination $projectFolder

Write-Host "##vso[artifact.upload containerfolder=artifact;artifactname=artifact]$projectFolder/$assemblyName.csproj"
$destProjectFile = Join-Path $projectFolder "$assemblyName.csproj"
$nugetConfigFile = Join-Path $PSScriptRoot "../../nuget.config"

Copy-Item -Path $sourceProjectFile -Destination $destProjectFile -Force -Verbose
Copy-Item -Path $nugetConfigFile -Destination $projectFolder -Verbose

Write-Host "##vso[artifact.upload containerfolder=artifact;artifactname=artifact]$destProjectFile"
Write-Host "##vso[artifact.upload containerfolder=artifact;artifactname=artifact]$generatedSource"

$arguments = GenerateBuildArguments -AssemblyName $assemblyName -RefAssemblyVersion $RefAssemblyVersion -SnkFilePath $SnkFilePath -SMAReferencePath $SMAReferenceAssembly
Expand Down
20 changes: 11 additions & 9 deletions tools/releaseBuild/azureDevOps/templates/nuget.yml
Original file line number Diff line number Diff line change
Expand Up @@ -201,16 +201,18 @@ jobs:
$packagePathList = Get-ChildItem $packagePath -Recurse | Select-Object -ExpandProperty FullName | Out-String
Write-Verbose -Verbose $packagePathList

Get-ChildItem -Path $packagePath |
$checksums = Get-ChildItem -Path $packagePath |
ForEach-Object {
Write-Verbose -Verbose "Generating checksum file for $($_.FullName)"
$packageName = $_.Name
$hash = (Get-FileHash -Path $_.FullName -Algorithm SHA512).Hash.ToLower()

# the '*' before the packagename signifies it is a binary
"$hash *$packageName"
} |
Out-File -FilePath "$packagePath\SHA512SUMS" -Force
Write-Verbose -Verbose "Generating checksum file for $($_.FullName)"
$packageName = $_.Name
$hash = (Get-FileHash -Path $_.FullName -Algorithm SHA512).Hash.ToLower()

# the '*' before the packagename signifies it is a binary
"$hash *$packageName"
}

$checksums | Out-File -FilePath "$packagePath\SHA512SUMS" -Force


$fileContent = Get-Content -Path "$packagePath\SHA512SUMS" -Raw | Out-String
Write-Verbose -Verbose -Message $fileContent
Expand Down