Skip to content

Commit

Permalink
Cache nuget packages
Browse files Browse the repository at this point in the history
  • Loading branch information
charlesbetros authored Nov 22, 2022
1 parent acaa092 commit 658a43f
Showing 1 changed file with 24 additions and 14 deletions.
38 changes: 24 additions & 14 deletions .github/workflows/pr.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ jobs:
runs-on: windows-2022

env:
USER_KIT_PATH: 'C:\\CosmosRun\\'
USER_KIT_PATH: 'C:\CosmosRun\'
BOCHS_RUN_CMD: '\"C:\Program Files (x86)\Bochs-2.6.8\Bochs.exe\" -q -f \"%1\"'

steps:
Expand All @@ -22,36 +22,46 @@ jobs:
repository: CosmosOS/Cosmos
path: Cosmos

- name: Checkout Common
uses: actions/checkout@v3
with:
repository: CosmosOS/Common
path: Common
# - name: Checkout Common
# uses: actions/checkout@v3
# with:
# repository: CosmosOS/Common
# path: Common

- name: Checkout IL2CPU
uses: actions/checkout@v3
with:
repository: CosmosOS/IL2CPU
path: IL2CPU

- name: Checkout XSharp
uses: actions/checkout@v3
with:
repository: CosmosOS/XSharp
path: XSharp
# - name: Checkout XSharp
# uses: actions/checkout@v3
# with:
# repository: CosmosOS/XSharp
# path: XSharp

- name: Setup MSBuild
uses: microsoft/[email protected]

- name: Setup Registry
run: |
Write-Host "Setting Cosmos User Kit Path to $($env:USER_KIT_PATH)"
reg add HKLM\SOFTWARE\WOW6432Node\Cosmos /v UserKit /d $($env:USER_KIT_PATH)
reg add HKLM\SOFTWARE\WOW6432Node\Cosmos /v UserKit /d "$($env:USER_KIT_PATH)"
reg query HKLM\SOFTWARE\WOW6432Node\Cosmos
Write-Host "Setting Bochs Run Command to $($env:BOCHS_RUN_CMD)"
reg add HKCR\BochsConfigFile\shell\Run\command /ve /d "$($env:BOCHS_RUN_CMD)"
reg query HKCR\BochsConfigFile\shell\Run\command
- name: Nuget - Cache
uses: actions/cache@v3
with:
path: ~/.nuget/packages
key: ${{ runner.os }}-nuget-${{ hashFiles('**/packages.lock.json') }}
restore-keys: |
${{ runner.os }}-nuget
- name: Nuget Restore
- name: Nuget - Restore
run: |
msbuild Cosmos\Build.sln /t:Restore /maxcpucount /verbosity:normal /p:Net48=True
Expand Down

0 comments on commit 658a43f

Please sign in to comment.