diff --git a/.github/workflows/Lagrange.OneBot-build.yml b/.github/workflows/Lagrange.OneBot-build.yml index 7c6b151c6..b6c6907e7 100644 --- a/.github/workflows/Lagrange.OneBot-build.yml +++ b/.github/workflows/Lagrange.OneBot-build.yml @@ -49,20 +49,13 @@ jobs: - name: Install .NET uses: actions/setup-dotnet@v4 with: - dotnet-version: '8.0.x' - - - name: Build Lagrange.OneBot .NET 7.0 - run: dotnet publish Lagrange.OneBot/Lagrange.OneBot.csproj --no-self-contained -p:PublishSingleFile=true -p:IncludeNativeLibrariesForSelfExtract=true -p:DebugType=none -p:RuntimeIdentifier=${{ matrix.runtimeIdentifier }} --framework net7.0 - + dotnet-version: '9.0.x' + - name: Build Lagrange.OneBot .NET 8.0 run: dotnet publish Lagrange.OneBot/Lagrange.OneBot.csproj --no-self-contained -p:PublishSingleFile=true -p:IncludeNativeLibrariesForSelfExtract=true -p:DebugType=none -p:RuntimeIdentifier=${{ matrix.runtimeIdentifier }} --framework net8.0 - - name: Upload binary files(${{ matrix.runtimeIdentifier }}) for .NET 7.0 - uses: actions/upload-artifact@v4 - if: github.event_name != 'pull_request' - with: - name: Lagrange.OneBot_${{ matrix.runtimeIdentifier }}_net7.0_NoSelfContained - path: Lagrange.OneBot/bin/Debug/net7.0/${{ matrix.runtimeIdentifier }}/publish + - name: Build Lagrange.OneBot .NET 9.0 + run: dotnet publish Lagrange.OneBot/Lagrange.OneBot.csproj --no-self-contained -p:PublishSingleFile=true -p:IncludeNativeLibrariesForSelfExtract=true -p:DebugType=none -p:RuntimeIdentifier=${{ matrix.runtimeIdentifier }} --framework net9.0 - name: Upload binary files(${{ matrix.runtimeIdentifier }}) for .NET 8.0 uses: actions/upload-artifact@v4 @@ -70,3 +63,10 @@ jobs: with: name: Lagrange.OneBot_${{ matrix.runtimeIdentifier }}_net8.0_NoSelfContained path: Lagrange.OneBot/bin/Release/net8.0/${{ matrix.runtimeIdentifier }}/publish + + - name: Upload binary files(${{ matrix.runtimeIdentifier }}) for .NET 9.0 + uses: actions/upload-artifact@v4 + if: github.event_name != 'pull_request' + with: + name: Lagrange.OneBot_${{ matrix.runtimeIdentifier }}_net9.0_NoSelfContained + path: Lagrange.OneBot/bin/Release/net8.0/${{ matrix.runtimeIdentifier }}/publish diff --git a/Lagrange.OneBot/Lagrange.OneBot.csproj b/Lagrange.OneBot/Lagrange.OneBot.csproj index 53085aa3c..354262ec6 100644 --- a/Lagrange.OneBot/Lagrange.OneBot.csproj +++ b/Lagrange.OneBot/Lagrange.OneBot.csproj @@ -9,7 +9,7 @@ Lagrange.OneBot https://github.com/LagrangeDev/Lagrange.Core git - net7.0;net8.0;net9.0 + net8.0;net9.0