Commit f6ae8dd
authored
ci: add caching for NuGet packages in CI workflows (#522)
Signed-off-by: André Silva <2493377+askpt@users.noreply.github.com>
<!-- Please use this template for your pull request. -->
<!-- Please use the sections that you need and delete other sections -->
## This PR
<!-- add the description of the PR here -->
This pull request enhances the CI/CD workflows by adding caching for
NuGet packages across multiple workflow files. This change aims to
improve build performance by avoiding repeated downloads of
dependencies.
### Workflow Improvements:
*
[`.github/workflows/ci.yml`](diffhunk://#diff-b803fcb7f17ed9235f1e5cb1fcd2f5d3b2838429d4368ae4c57ce4436577f03fR39-R46):
Added a step to cache NuGet packages in both the main CI job and another
job within the same file. This uses the `actions/cache` action to store
packages in `~/.nuget/packages` and leverages file hashing for cache
keys.
[[1]](diffhunk://#diff-b803fcb7f17ed9235f1e5cb1fcd2f5d3b2838429d4368ae4c57ce4436577f03fR39-R46)
[[2]](diffhunk://#diff-b803fcb7f17ed9235f1e5cb1fcd2f5d3b2838429d4368ae4c57ce4436577f03fR82-R89)
*
[`.github/workflows/code-coverage.yml`](diffhunk://#diff-49708f979e226a1e7bd7a68d71b2e91aae8114dd3e9254d9830cd3b4d62d4303R37-R44):
Introduced NuGet package caching to the code coverage workflow,
improving efficiency during the `dotnet test` step.
*
[`.github/workflows/e2e.yml`](diffhunk://#diff-3e103440521ada06efd263ae09b259e5507e4b8f7408308dc227621ad9efa31eR32-R39):
Added caching for NuGet packages in the end-to-end testing workflow,
reducing setup time for dependencies.
*
[`.github/workflows/release.yml`](diffhunk://#diff-87db21a973eed4fef5f32b267aa60fcee5cbdf03c67fafdc2a9b553bb0b15f34R54-R61):
Implemented NuGet package caching in the release workflow to optimize
dependency installation during the `dotnet restore` step.
### Notes
<!-- any additional notes for this PR -->
This is similar to
open-feature/dotnet-sdk-contrib#453
---------
Signed-off-by: André Silva <2493377+askpt@users.noreply.github.com>1 parent fbc2645 commit f6ae8dd
File tree
4 files changed
+40
-0
lines changed- .github/workflows
4 files changed
+40
-0
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
36 | 36 | | |
37 | 37 | | |
38 | 38 | | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
39 | 47 | | |
40 | 48 | | |
41 | 49 | | |
| |||
71 | 79 | | |
72 | 80 | | |
73 | 81 | | |
| 82 | + | |
| 83 | + | |
| 84 | + | |
| 85 | + | |
| 86 | + | |
| 87 | + | |
| 88 | + | |
| 89 | + | |
74 | 90 | | |
75 | 91 | | |
76 | 92 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
34 | 34 | | |
35 | 35 | | |
36 | 36 | | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
37 | 45 | | |
38 | 46 | | |
39 | 47 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
29 | 29 | | |
30 | 30 | | |
31 | 31 | | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
32 | 40 | | |
33 | 41 | | |
34 | 42 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
51 | 51 | | |
52 | 52 | | |
53 | 53 | | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
54 | 62 | | |
55 | 63 | | |
56 | 64 | | |
| |||
0 commit comments