From 6166ed626ce800832055b58ecaf6fcef488813f5 Mon Sep 17 00:00:00 2001 From: djek-sweng Date: Wed, 3 Jan 2024 22:27:12 +0100 Subject: [PATCH] Update SDK .NET8 --- src/.editorconfig => .editorconfig | 4 +-- .github/workflows/dotnet.yml | 36 +++++++++++++++++++ README.md | 16 +++------ app_build.sh | 2 -- app_clean.sh | 2 -- app_run.sh | 16 ++++----- src/global.json => global.json | 2 +- src/Directory.Build.props | 21 +++++------ .../EFCore.TableMapping.Shared.csproj | 6 ++++ .../EFCore.TableMapping.WebApi.Tpc.csproj | 12 ++++--- .../EFCore.TableMapping.WebApi.Tph.csproj | 12 ++++--- .../EFCore.TableMapping.WebApi.Tpt.csproj | 12 ++++--- 12 files changed, 91 insertions(+), 50 deletions(-) rename src/.editorconfig => .editorconfig (90%) create mode 100644 .github/workflows/dotnet.yml rename src/global.json => global.json (76%) diff --git a/src/.editorconfig b/.editorconfig similarity index 90% rename from src/.editorconfig rename to .editorconfig index 463bd13..37c4854 100644 --- a/src/.editorconfig +++ b/.editorconfig @@ -2,7 +2,7 @@ root = true # Unix-style newlines with a newline ending every file -[*cs] +[*.cs] end_of_line = lf insert_final_newline = true indent_style = space @@ -10,7 +10,7 @@ indent_size = 4 trim_trailing_whitespace = true charset = utf-8 -[*{csproj,targets,props,sh}] +[*.{csproj,targets,props,sh}] end_of_line = lf insert_final_newline = true indent_style = space diff --git a/.github/workflows/dotnet.yml b/.github/workflows/dotnet.yml new file mode 100644 index 0000000..86e2373 --- /dev/null +++ b/.github/workflows/dotnet.yml @@ -0,0 +1,36 @@ +name: .NET + +on: + push: + branches: + - main + - feature/** + pull_request: + branches: + - main + - feature/** + workflow_dispatch: + +jobs: + build: + + runs-on: ubuntu-latest + + steps: + - uses: actions/checkout@v3 + - name: Setup .NET + uses: actions/setup-dotnet@v3 + with: + dotnet-version: 8.0.x + - name: Restore dependencies + run: | + cd src/ + dotnet restore Wizards.sln + - name: Build + run: | + cd src/ + dotnet build Wizards.sln --no-restore + - name: Test + run: | + cd src/ + dotnet test Wizards.sln --no-build --verbosity normal diff --git a/README.md b/README.md index e892676..7717221 100644 --- a/README.md +++ b/README.md @@ -244,21 +244,13 @@ http://localhost:5102/swagger #### **Toolchain Requirements and Versions** ```sh -$ dotnet --info - .NET SDK: - Version: 7.0.306 - - .NET SDKs installed: - 7.0.306 - - .NET runtimes installed: - Microsoft.AspNetCore.App 7.0.9 - Microsoft.NETCore.App 7.0.9 +$ dotnet --version + 8.0.100 $ dotnet ef --version Entity Framework Core .NET Command-line Tools - 7.0.10 + 8.0.0 $ sqlite3 --version - 3.39.5 + 3.43.2 ``` diff --git a/app_build.sh b/app_build.sh index ead1e59..4c35a8e 100755 --- a/app_build.sh +++ b/app_build.sh @@ -3,5 +3,3 @@ SLN_FILE="./src/EFCore.TableMapping.sln" dotnet build "$SLN_FILE" - -exit 0 diff --git a/app_clean.sh b/app_clean.sh index ceb1616..b9e74ac 100755 --- a/app_clean.sh +++ b/app_clean.sh @@ -3,5 +3,3 @@ SLN_FILE="./src/EFCore.TableMapping.sln" dotnet clean "$SLN_FILE" - -exit 0 diff --git a/app_run.sh b/app_run.sh index 3b8d064..c88a81d 100755 --- a/app_run.sh +++ b/app_run.sh @@ -2,28 +2,26 @@ if [ $# -eq 0 ] then - echo "Pass input argument." - exit -1 + echo "Pass input argument." + exit -1 elif [ "$1" == "tph" ] then - CSPORJ="Tph" + CSPORJ="Tph" elif [ "$1" == "tpt" ] then - CSPORJ="Tpt" + CSPORJ="Tpt" elif [ "$1" == "tpc" ] then - CSPORJ="Tpc" + CSPORJ="Tpc" else - echo "Invalid input argument." - exit -1 + echo "Invalid input argument." + exit -1 fi CSPORJ_FILE="./src/EFCore.TableMapping.WebApi."$CSPORJ"/EFCore.TableMapping.WebApi."$CSPORJ".csproj" dotnet run --project "$CSPORJ_FILE" --launch-profile "https" - -exit 0 diff --git a/src/global.json b/global.json similarity index 76% rename from src/global.json rename to global.json index 974d4c4..4c4c3ae 100644 --- a/src/global.json +++ b/global.json @@ -1,6 +1,6 @@ { "sdk": { - "version": "7.0.306", + "version": "8.0.100", "rollForward": "latestFeature", "allowPrerelease": false } diff --git a/src/Directory.Build.props b/src/Directory.Build.props index 33c41c4..307b0f3 100644 --- a/src/Directory.Build.props +++ b/src/Directory.Build.props @@ -1,28 +1,29 @@ - net7.0 - 11.0 + net8.0 + 12.0 enable enable true + true - - + + - - + + all runtime; build; native; contentfiles; analyzers - - + + all runtime; build; native; contentfiles; analyzers; buildtransitive - - + + diff --git a/src/EFCore.TableMapping.Shared/EFCore.TableMapping.Shared.csproj b/src/EFCore.TableMapping.Shared/EFCore.TableMapping.Shared.csproj index 624a232..6f39fc5 100644 --- a/src/EFCore.TableMapping.Shared/EFCore.TableMapping.Shared.csproj +++ b/src/EFCore.TableMapping.Shared/EFCore.TableMapping.Shared.csproj @@ -1,5 +1,11 @@ + + + + + + diff --git a/src/EFCore.TableMapping.WebApi.Tpc/EFCore.TableMapping.WebApi.Tpc.csproj b/src/EFCore.TableMapping.WebApi.Tpc/EFCore.TableMapping.WebApi.Tpc.csproj index 343790e..192e43b 100644 --- a/src/EFCore.TableMapping.WebApi.Tpc/EFCore.TableMapping.WebApi.Tpc.csproj +++ b/src/EFCore.TableMapping.WebApi.Tpc/EFCore.TableMapping.WebApi.Tpc.csproj @@ -1,5 +1,13 @@ + + + + + + + + @@ -7,8 +15,4 @@ - - - - diff --git a/src/EFCore.TableMapping.WebApi.Tph/EFCore.TableMapping.WebApi.Tph.csproj b/src/EFCore.TableMapping.WebApi.Tph/EFCore.TableMapping.WebApi.Tph.csproj index c094087..806ebe3 100644 --- a/src/EFCore.TableMapping.WebApi.Tph/EFCore.TableMapping.WebApi.Tph.csproj +++ b/src/EFCore.TableMapping.WebApi.Tph/EFCore.TableMapping.WebApi.Tph.csproj @@ -1,5 +1,13 @@ + + + + + + + + @@ -7,8 +15,4 @@ - - - - diff --git a/src/EFCore.TableMapping.WebApi.Tpt/EFCore.TableMapping.WebApi.Tpt.csproj b/src/EFCore.TableMapping.WebApi.Tpt/EFCore.TableMapping.WebApi.Tpt.csproj index 508c29b..3fc1e68 100644 --- a/src/EFCore.TableMapping.WebApi.Tpt/EFCore.TableMapping.WebApi.Tpt.csproj +++ b/src/EFCore.TableMapping.WebApi.Tpt/EFCore.TableMapping.WebApi.Tpt.csproj @@ -1,5 +1,13 @@ + + + + + + + + @@ -7,8 +15,4 @@ - - - -