Skip to content

Commit

Permalink
CI: github actions to build project
Browse files Browse the repository at this point in the history
  • Loading branch information
davelim committed Oct 30, 2024
1 parent 2f15a68 commit 0aef05b
Show file tree
Hide file tree
Showing 2 changed files with 59 additions and 0 deletions.
23 changes: 23 additions & 0 deletions .github/workflows/dotnet.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
name: Build .net core

on: [push]

jobs:
build:
name: Test ${{ matrix.os }} for dotnet ${{ matrix.dotnet }}
runs-on: ${{ matrix.os }}
strategy:
matrix:
dotnet: [ '8.0.x' ]
os: [ubuntu-latest, windows-latest, macOS-latest]

steps:
- uses: actions/checkout@v1
- name: Setup .NET Core
uses: actions/setup-dotnet@v1
with:
dotnet-version: ${{ matrix.dotnet }}
- name: Build with dotnet core
run: dotnet build --configuration Release
- name: Tests
run: dotnet test DotNetDBF.Test/DotNetDBF.Test.csproj --configuration Release --no-build --no-restore
36 changes: 36 additions & 0 deletions .github/workflows/dotnet48.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
name: Build CrossComple .net core/.net framework Windows

on: [push]

jobs:
build:
name: Test Windows .net Framework Only
runs-on: windows-2019
steps:
- uses: actions/checkout@v4

- name: Setup NuGet
uses: NuGet/setup-nuget@v2

- name: Setup MSBuild
uses: microsoft/setup-msbuild@v2
with:
dotnet-version: 4.7.2

# - name: Restore Packages
# run: nuget restore DotNetDBF.sln
# - name: Build solution
# run: msbuild DotNetDBF.sln -t:rebuild -property:Configuration=Release
# - name: Run vstests
# uses: microsoft/vstest-action@v1.0.0
# with:
# testAssembly: Tests.dll
# searchFolder: .\Tests\bin\Release\*\
# runInParallel: true
# platform: x64
- name: Restore
run: nuget restore DotNetDBF.sln
- name: Build
run: msbuild DotNetDBF.sln -t:rebuild -property:Configuration=Release
- name: Test
run: dotnet test --configuration Release --no-build --no-restore

0 comments on commit 0aef05b

Please sign in to comment.