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

feat: Cache NuGet global-packages folder #303

Merged
merged 35 commits into from
May 29, 2023
Merged
Show file tree
Hide file tree
Changes from 27 commits
Commits
Show all changes
35 commits
Select commit Hold shift + click to select a range
af15115
feat: cache NuGet global-packages folder
nogic1008 Apr 25, 2023
8752594
fix: remove unused files
nogic1008 Apr 25, 2023
4e3fa35
docs: fix incorrect action
nogic1008 Apr 25, 2023
71228fd
ci: add e2e test for cache
nogic1008 Apr 26, 2023
b40f9e8
docs: accept suggested changes on README
nogic1008 Apr 26, 2023
2683943
docs: add simple cache example
nogic1008 Apr 26, 2023
3fcae62
build: change main script path
nogic1008 Apr 26, 2023
061d7af
fix: change relative path to install scripts
nogic1008 Apr 26, 2023
cffdfc8
fix: change relative path to problem matcher
nogic1008 Apr 26, 2023
d958ca3
refactor: accept changes on cache-utils
nogic1008 Apr 27, 2023
3025f77
fix: revert main script path changes
nogic1008 Apr 27, 2023
6985ab3
test: fix cache-utils unit test
nogic1008 Apr 27, 2023
15b6d31
test: fix cache-utils unit test
nogic1008 Apr 27, 2023
9bc24e1
feat: add `cache-dependency-path` variables
nogic1008 Apr 30, 2023
c2b95dc
build: change main script dist path
nogic1008 Apr 30, 2023
0f40f1c
ci: add `cache-dependency-path` e2e test & missing lock file
nogic1008 Apr 30, 2023
9703c80
fix: accept change suggestions
nogic1008 May 10, 2023
f55c1f4
ci: copy NuGet lock file to root
nogic1008 May 10, 2023
5b9469d
docs: change README guide
nogic1008 May 10, 2023
1b0bc35
fix: apply suggestions from code review
nogic1008 May 11, 2023
ee0d3b4
test: fix some failed unit tests
nogic1008 May 12, 2023
5cde892
build: rebuild dist
nogic1008 May 12, 2023
23aaf1d
Merge branch 'actions/main' into feat/nuget-cache
May 15, 2023
79ba22d
Update unit-tests
May 16, 2023
4c5e506
Update unit tests for unix systems
May 17, 2023
b50a1c9
Format and lint unit tests
May 17, 2023
499093f
Merge pull request #1 from IvanZosimov/nuget-cache/update-unit-tests
nogic1008 May 17, 2023
39d3726
fix: avoid use '/' on `path.join`
nogic1008 May 23, 2023
72ff56e
Merge remote-tracking branch 'origin/main' into feat/nuget-cache
nogic1008 May 24, 2023
173e371
fix: rebuild dist
nogic1008 May 24, 2023
4a7f04a
fix: apply suggestions from code review
nogic1008 May 28, 2023
0a1e793
Merge remote-tracking branch 'origin/main' into feat/nuget-cache
nogic1008 May 28, 2023
248bcfb
build: add `DisableImplicitNuGetFallbackFolder` option
nogic1008 May 28, 2023
10e8639
docs: highlight warnings and notes
May 29, 2023
78b8e27
docs: update note about handling NU1403
May 29, 2023
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
60 changes: 60 additions & 0 deletions .github/workflows/e2e-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -205,6 +205,66 @@ jobs:
shell: pwsh
run: __tests__/verify-dotnet.ps1 -Patterns "^7\.0\.\d+-"

test-setup-with-cache:
runs-on: ${{ matrix.operating-system }}
strategy:
fail-fast: false
matrix:
operating-system: [ubuntu-latest, windows-latest, macos-latest]
env:
NUGET_PACKAGES: ${{ github.workspace }}/.nuget/packages
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Clear toolcache
shell: pwsh
run: __tests__/clear-toolcache.ps1 ${{ runner.os }}
- name: Copy NuGet lock file to root
shell: bash
run: cp ./__tests__/e2e-test-csproj/packages.lock.json ./packages.lock.json
- name: Setup .NET Core 3.1
id: setup-dotnet
uses: ./
with:
dotnet-version: 3.1
cache: true
- name: Verify Cache
if: steps.setup-dotnet.outputs.cache-hit == 'true'
shell: bash
run: if [[ -e ${NUGET_PACKAGES} ]]; then exit 0; else exit 1; fi
- name: Verify dotnet
shell: pwsh
run: __tests__/verify-dotnet.ps1 -Patterns "^3.1"

test-setup-with-cache-dependency-path:
runs-on: ${{ matrix.operating-system }}
strategy:
fail-fast: false
matrix:
operating-system: [ubuntu-latest, windows-latest, macos-latest]
env:
NUGET_PACKAGES: ${{ github.workspace }}/.nuget/packages
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Clear toolcache
shell: pwsh
run: __tests__/clear-toolcache.ps1 ${{ runner.os }}
- name: Setup .NET Core 3.1
id: setup-dotnet
uses: ./
with:
dotnet-version: 3.1
cache: true
cache-dependency-path: './__tests__/e2e-test-csproj/packages.lock.json'
- name: Verify Cache
if: steps.setup-dotnet.outputs.cache-hit == 'true'
shell: bash
run: if [[ -e ${NUGET_PACKAGES} ]]; then exit 0; else exit 1; fi
- name: Verify dotnet
shell: pwsh
run: __tests__/verify-dotnet.ps1 -Patterns "^3.1"

test-dotnet-version-output-during-single-version-installation:
runs-on: ${{ matrix.operating-system }}
strategy:
Expand Down
4 changes: 3 additions & 1 deletion .licensed.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ sources:

allowed:
- apache-2.0
- 0bsd
- bsd-2-clause
- bsd-3-clause
- isc
Expand All @@ -11,4 +12,5 @@ allowed:
- unlicense

reviewed:
npm:
npm:
- sax # ISC + MIT
20 changes: 20 additions & 0 deletions .licenses/npm/@actions/cache.dep.yml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

20 changes: 20 additions & 0 deletions .licenses/npm/@actions/glob-0.1.2.dep.yml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

20 changes: 20 additions & 0 deletions .licenses/npm/@actions/glob-0.3.0.dep.yml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

32 changes: 32 additions & 0 deletions .licenses/npm/@azure/abort-controller.dep.yml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

33 changes: 33 additions & 0 deletions .licenses/npm/@azure/core-auth.dep.yml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

33 changes: 33 additions & 0 deletions .licenses/npm/@azure/core-http.dep.yml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

33 changes: 33 additions & 0 deletions .licenses/npm/@azure/core-lro.dep.yml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

32 changes: 32 additions & 0 deletions .licenses/npm/@azure/core-paging.dep.yml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

32 changes: 32 additions & 0 deletions .licenses/npm/@azure/core-tracing.dep.yml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

32 changes: 32 additions & 0 deletions .licenses/npm/@azure/core-util.dep.yml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading