Skip to content

use .net 8 as sample instead #25

use .net 8 as sample instead

use .net 8 as sample instead #25

Workflow file for this run

name: DotNet
on:
workflow_dispatch:
pull_request:
branches: [main]
push:
branches: [main]
env:
DOTNET_NOLOGO: true
DOTNET_CLI_TELEMETRY_OPTOUT: 1
DOTNET_SKIP_FIRST_TIME_EXPERIENCE: true
POWERSHELL_TELEMETRY_OPTOUT: 1
NUGET_PACKAGES: ${{ github.workspace }}/.nuget/packages
jobs:
build:
runs-on: ${{ matrix.os }}
name: Test
strategy:
matrix:
os: [ubuntu-latest, macos-latest, windows-2019, windows-2022]
cache: [true, false]
fail-fast: false
steps:
- name: Checkout
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Cache NuGet packages
if: matrix.cache
uses: actions/cache@v3
with:
path: ${{ github.workspace }}/.nuget/packages
key: ${{ runner.os }}-nuget-${{ hashFiles('**/packages.lock.json') }}
restore-keys: ${{ runner.os }}-nuget-
- name: Setup DotNet 8
uses: actions/setup-dotnet@v3
with:
dotnet-version: 8.0.x
dotnet-quality: 'preview'
- name: DotNet restore
run: |
dotnet new nugetconfig
dotnet restore -v n