Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use RestoreNoHttpCache instead of RestoreNoCache for nuget #14824

Merged
merged 1 commit into from
Jun 10, 2024
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
Use RestoreNoHttpCache instead of RestoreNoCache for nuget
nuget renamed this option in https://github.com/NuGet/Home/blob/dev/accepted/2023/Add-NoHttpCacheOption.md?plain=1 and prints a message that says the old option is deprecated in the binlog which can be confusing.
  • Loading branch information
akoeplinger committed Jun 7, 2024
commit 67bb85b8ac8a2f003248d87a05f0cce3b13e7b0c
2 changes: 1 addition & 1 deletion eng/common/tools.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -653,7 +653,7 @@ function GetNuGetPackageCachePath() {
$env:NUGET_PACKAGES = Join-Path $env:UserProfile '.nuget\packages\'
} else {
$env:NUGET_PACKAGES = Join-Path $RepoRoot '.packages\'
$env:RESTORENOCACHE = $true
$env:RESTORENOHTTPCACHE = $true
}
}

Expand Down
4 changes: 2 additions & 2 deletions eng/common/tools.sh
Original file line number Diff line number Diff line change
Expand Up @@ -347,14 +347,14 @@ function InitializeBuildTool {
fi
}

# Set RestoreNoCache as a workaround for https://github.com/NuGet/Home/issues/3116
# Set RestoreNoHttpCache as a workaround for https://github.com/NuGet/Home/issues/3116
function GetNuGetPackageCachePath {
if [[ -z ${NUGET_PACKAGES:-} ]]; then
if [[ "$use_global_nuget_cache" == true ]]; then
export NUGET_PACKAGES="$HOME/.nuget/packages"
else
export NUGET_PACKAGES="$repo_root/.packages"
export RESTORENOCACHE=true
export RESTORENOHTTPCACHE=true
fi
fi

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
Workaround for https://github.com/NuGet/Home/issues/3116
-->
<PropertyGroup>
<RestoreNoCache Condition="'$(ContinuousIntegrationBuild)' == 'true'">true</RestoreNoCache>
<RestoreNoHttpCache Condition="'$(ContinuousIntegrationBuild)' == 'true'">true</RestoreNoHttpCache>
</PropertyGroup>

<!--
Expand Down
Loading