Compare commits

...

1 Commits

Author SHA1 Message Date
Scott Hanselman
d395c11117 ci: add NuGet package caching to test job
Adds actions/cache@v4 for ~/.nuget/packages keyed on csproj hashes.
Saves ~30-60s on subsequent CI runs by reusing cached packages.

Uses csproj hash (not lock files) since this repo doesn't use
packages.lock.json, which is why setup-dotnet's cache: true won't work.

Based on Repo Assist suggestion (#66).

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
2026-03-18 10:07:13 -07:00

View File

@ -20,6 +20,13 @@ jobs:
with:
dotnet-version: 10.0.x
- name: Cache NuGet packages
uses: actions/cache@v4
with:
path: ~/.nuget/packages
key: nuget-${{ runner.os }}-${{ hashFiles('**/*.csproj') }}
restore-keys: nuget-${{ runner.os }}-
- name: Install GitVersion
uses: gittools/actions/gitversion/setup@v4
with: