diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml new file mode 100644 index 0000000..dda509f --- /dev/null +++ b/.github/workflows/ci.yml @@ -0,0 +1,21 @@ +name: CI + +on: + push: + branches: [ "main" ] + pull_request: + branches: [ "main" ] + +jobs: + test: + runs-on: ubuntu-latest + container: mcr.microsoft.com/dotnet/sdk:7.0 + + steps: + - name: Checkout + uses: actions/checkout@v3 + - name: Build + run: ./build.sh + - name: Test + run: ./test.sh + diff --git a/build.sh b/build.sh old mode 100644 new mode 100755 index 433a9b4..661769f --- a/build.sh +++ b/build.sh @@ -1,11 +1,3 @@ -#!/bin/bash -dotnet --info +#!/usr/bin/env bash dotnet restore - -for path in src/**/*.csproj; do - dotnet build -f netstandard2.0 -c Release ${path} -done - -for path in test/*.Tests/*.csproj; do - dotnet test -f netcoreapp2.0 -c Release ${path} -done +dotnet build -c Release \ No newline at end of file diff --git a/test.sh b/test.sh new file mode 100755 index 0000000..d1b407f --- /dev/null +++ b/test.sh @@ -0,0 +1,2 @@ +#!/usr/bin/env bash +dotnet test -c Release \ No newline at end of file