Skip to content

Adds .NET 8 support #76

Adds .NET 8 support

Adds .NET 8 support #76

Workflow file for this run

name: Main
on:
push:
branches:
- master
# Publish `v1.2.3` tags as releases.
tags:
- v*
# Testing - run for any PRs.
pull_request:
branches:
- master
jobs:
# Build, test and publish (if this is a push/merge).
build-and-test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Setup .NET Core 3.1
uses: actions/setup-dotnet@v1
with:
dotnet-version: 3.1.x
- name: Setup .NET 5.0
uses: actions/setup-dotnet@v1
with:
dotnet-version: 5.0.x
- name: Setup .NET 6.0
uses: actions/setup-dotnet@v1
with:
dotnet-version: 6.0.x
- name: Setup .NET 7.0
uses: actions/setup-dotnet@v1
with:
dotnet-version: 7.0.x
- name: Setup .NET 8.0
uses: actions/setup-dotnet@v1
with:
dotnet-version: 8.0.x
- name: Install dependencies
run: dotnet restore
- name: Build
run: dotnet build --configuration Release --no-restore
- name: Test
run: dotnet test --no-restore --verbosity normal
publish-package:
needs: build-and-test
runs-on: ubuntu-latest
if: github.event_name == 'push'
steps:
- uses: actions/checkout@v4
- name: Setup .NET Core 8.0
uses: actions/setup-dotnet@v1
with:
dotnet-version: 8.0.x
- name: Install dependencies
run: dotnet restore
- name: Build
run: dotnet build --configuration Release --no-restore
- name: Pack
run: dotnet pack --no-build --configuration Release DataTables.Blazor/DataTables.Blazor.csproj --output .
- name: publish to nuget.org on version change
id: publish_nuget
uses: alirezanet/publish-nuget@v3.0.4
with:
PROJECT_FILE_PATH: DataTables.Blazor/DataTables.Blazor.csproj
VERSION_REGEX: <Version>(.*)<\/Version>
TAG_COMMIT: true
TAG_FORMAT: v*
INCLUDE_SYMBOLS: true
NO_BUILD: true
NUGET_KEY: ${{secrets.NUGET_KEY}}
- name: Publish to github packages
uses: tanaka-takayoshi/nuget-publish-to-github-packages-action@v2.1
with:
nupkg-path: '*.nupkg'
repo-owner: 'JustinWilkinson'
gh-user: 'JustinWilkinson'
token: ${{secrets.GITHUB_TOKEN}}