Update GitHub worker workflow

This commit is contained in:
genteure 2022-04-03 20:21:55 +08:00
parent 43ed74919b
commit bc8ec0b000
2 changed files with 9 additions and 26 deletions

View File

@ -23,15 +23,9 @@ jobs:
uses: actions/checkout@v2
with:
fetch-depth: 0
- name: Cache Nuget Packages
uses: actions/cache@v2
with:
path: ${{ github.workspace }}/.nuget/packages
key: ${{ runner.os }}-nuget-${{ hashFiles('**/*.csproj') }}
restore-keys: |
${{ runner.os }}-nuget-
- uses: actions/setup-dotnet@v2
- name: Restore Packages
run: dotnet restore -v m
run: dotnet restore -v m --disable-parallel
- name: Run Tests
run: dotnet test -v m
@ -46,15 +40,8 @@ jobs:
uses: actions/checkout@v2
with:
fetch-depth: 0
- name: Cache Nuget Packages
uses: actions/cache@v2
with:
path: ${{ github.workspace }}/.nuget/packages
key: ${{ runner.os }}-nuget-${{ hashFiles('**/*.csproj') }}
restore-keys: |
${{ runner.os }}-nuget-
- name: Add msbuild to PATH
uses: microsoft/setup-msbuild@v1.0.2
uses: microsoft/setup-msbuild@v1.1
- name: Restore Packages
run: nuget restore -Verbosity quiet
- name: Build WPF
@ -77,15 +64,9 @@ jobs:
uses: actions/checkout@v2
with:
fetch-depth: 0
- name: Cache Nuget Packages
uses: actions/cache@v2
with:
path: ${{ github.workspace }}/.nuget/packages
key: ${{ runner.os }}-nuget-${{ hashFiles('**/*.csproj') }}
restore-keys: |
${{ runner.os }}-nuget-
- uses: actions/setup-dotnet@v2
- name: Restore Packages
run: dotnet restore -v m
run: dotnet restore -v m --disable-parallel
- name: Build CLI
if: ${{ matrix.rid == 'any' }}
run: dotnet publish -c ${{ matrix.build_configuration }} BililiveRecorder.Cli/BililiveRecorder.Cli.csproj

View File

@ -22,8 +22,9 @@ jobs:
uses: actions/checkout@v2
with:
fetch-depth: 0
- uses: actions/setup-dotnet@v2
- name: Restore Packages
run: dotnet restore -v m
run: dotnet restore -v m --disable-parallel
- name: Run Tests
run: dotnet test -v m
@ -80,8 +81,9 @@ jobs:
uses: actions/checkout@v2
with:
fetch-depth: 0
- uses: actions/setup-dotnet@v2
- name: Restore Packages
run: dotnet restore -v m
run: dotnet restore -v m --disable-parallel
- name: Build CLI
if: ${{ matrix.rid == 'any' }}
run: dotnet publish -c ${{ matrix.build_configuration }} BililiveRecorder.Cli/BililiveRecorder.Cli.csproj