From 02c503c9775810cdf63119179d8a7288975e0bd0 Mon Sep 17 00:00:00 2001 From: Argo Window10 Date: Wed, 11 Dec 2019 23:44:12 +0800 Subject: [PATCH] =?UTF-8?q?build:=20=E9=A1=B9=E7=9B=AE=E5=8D=87=E7=BA=A7?= =?UTF-8?q?=E5=88=B0=20NETCore=203.1=20=E7=89=88=E6=9C=AC?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/workflows/build.yml | 2 +- appveyor.yml | 2 +- src/Directory.Build.props | 4 +-- .../Bootstrap.Admin/Bootstrap.Admin.csproj | 6 ++-- src/admin/Bootstrap.Admin/Dockerfile | 4 +-- src/admin/Bootstrap.Admin/Linux.Dockerfile | 4 +-- .../Bootstrap.DataAccess.MongoDB.csproj | 6 ++-- .../Bootstrap.DataAccess.csproj | 28 +++++++++---------- .../Helper/OAuthHelper.cs | 2 -- .../Helper/WeChatHelper.cs | 4 --- ...Bootstrap.Client.DataAccess.MongoDB.csproj | 4 +-- .../Bootstrap.Client.DataAccess.csproj | 16 +++++------ .../Bootstrap.Client/Bootstrap.Client.csproj | 6 ++-- test/UnitTest/UnitTest.csproj | 6 ++-- 14 files changed, 44 insertions(+), 50 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 5c5d8bcb..59fcdea8 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -14,6 +14,6 @@ jobs: - name: Setup .NET Core uses: actions/setup-dotnet@v1 with: - dotnet-version: 3.0.100 + dotnet-version: 3.1.100 - name: Build with dotnet run: dotnet build src/admin/Bootstrap.Admin/ --configuration Release \ No newline at end of file diff --git a/appveyor.yml b/appveyor.yml index cf7a0c69..388eced8 100644 --- a/appveyor.yml +++ b/appveyor.yml @@ -36,7 +36,7 @@ test_script: - ps: >- .\appveyor.test.ps1 artifacts: -- path: src\admin\Bootstrap.Admin\bin\release\netcoreapp3.0\publish\ +- path: src\admin\Bootstrap.Admin\bin\release\netcoreapp3.1\publish\ name: BootstrapAdmin type: WebDeployPackage deploy: diff --git a/src/Directory.Build.props b/src/Directory.Build.props index aad557b0..ad74f7d2 100644 --- a/src/Directory.Build.props +++ b/src/Directory.Build.props @@ -3,8 +3,8 @@ - https://gitee.com/LongbowGroup/$(MsBuildProjectName) - https://gitee.com/LongbowGroup/$(MsBuildProjectName).git + https://gitee.com/LongbowEnterprise/BootstrapAdmin + https://gitee.com/LongbowEnterprise/BootstrapAdmin.git git enable $(MSBuildProjectName).xml diff --git a/src/admin/Bootstrap.Admin/Bootstrap.Admin.csproj b/src/admin/Bootstrap.Admin/Bootstrap.Admin.csproj index 8af70d6c..0a4c5ead 100644 --- a/src/admin/Bootstrap.Admin/Bootstrap.Admin.csproj +++ b/src/admin/Bootstrap.Admin/Bootstrap.Admin.csproj @@ -1,7 +1,7 @@  - netcoreapp3.0 + netcoreapp3.1 true @@ -10,8 +10,8 @@ - - + + diff --git a/src/admin/Bootstrap.Admin/Dockerfile b/src/admin/Bootstrap.Admin/Dockerfile index 8cef6aa8..562baa96 100644 --- a/src/admin/Bootstrap.Admin/Dockerfile +++ b/src/admin/Bootstrap.Admin/Dockerfile @@ -1,11 +1,11 @@ #Depending on the operating system of the host machines(s) that will build or run the containers, the image specified in the FROM statement may need to be changed. #For more information, please see https://aka.ms/containercompat -FROM microsoft/dotnet:3.0-aspnetcore-runtime-nanoserver-1903 AS base +FROM microsoft/dotnet:3.1-aspnetcore-runtime-nanoserver-1903 AS base WORKDIR /app EXPOSE 80 -FROM microsoft/dotnet:3.0-sdk-nanoserver-1903 AS build +FROM microsoft/dotnet:3.1-sdk-nanoserver-1903 AS build WORKDIR /src COPY . . diff --git a/src/admin/Bootstrap.Admin/Linux.Dockerfile b/src/admin/Bootstrap.Admin/Linux.Dockerfile index 30238f7a..dc18813c 100644 --- a/src/admin/Bootstrap.Admin/Linux.Dockerfile +++ b/src/admin/Bootstrap.Admin/Linux.Dockerfile @@ -1,11 +1,11 @@ #Depending on the operating system of the host machines(s) that will build or run the containers, the image specified in the FROM statement may need to be changed. #For more information, please see https://aka.ms/containercompat -FROM mcr.microsoft.com/dotnet/core/aspnet:3.0 AS base +FROM mcr.microsoft.com/dotnet/core/aspnet:3.1 AS base WORKDIR /app EXPOSE 80 -FROM mcr.microsoft.com/dotnet/core/sdk:3.0 AS build +FROM mcr.microsoft.com/dotnet/core/sdk:3.1 AS build WORKDIR /src COPY . . diff --git a/src/admin/Bootstrap.DataAccess.MongoDB/Bootstrap.DataAccess.MongoDB.csproj b/src/admin/Bootstrap.DataAccess.MongoDB/Bootstrap.DataAccess.MongoDB.csproj index d6e0567d..27f112c1 100644 --- a/src/admin/Bootstrap.DataAccess.MongoDB/Bootstrap.DataAccess.MongoDB.csproj +++ b/src/admin/Bootstrap.DataAccess.MongoDB/Bootstrap.DataAccess.MongoDB.csproj @@ -1,12 +1,12 @@  - netcoreapp3.0 + netcoreapp3.1 - - + + diff --git a/src/admin/Bootstrap.DataAccess/Bootstrap.DataAccess.csproj b/src/admin/Bootstrap.DataAccess/Bootstrap.DataAccess.csproj index 936e01e6..2b20526e 100644 --- a/src/admin/Bootstrap.DataAccess/Bootstrap.DataAccess.csproj +++ b/src/admin/Bootstrap.DataAccess/Bootstrap.DataAccess.csproj @@ -1,25 +1,25 @@  - netcoreapp3.0 + netcoreapp3.1 - - - - - - - - + + + + + + + + - - - - - + + + + + diff --git a/src/admin/Bootstrap.DataAccess/Helper/OAuthHelper.cs b/src/admin/Bootstrap.DataAccess/Helper/OAuthHelper.cs index c18e1411..17cc24e4 100644 --- a/src/admin/Bootstrap.DataAccess/Helper/OAuthHelper.cs +++ b/src/admin/Bootstrap.DataAccess/Helper/OAuthHelper.cs @@ -50,7 +50,6 @@ namespace Bootstrap.DataAccess }; } -#if NETCOREAPP3_0 private static T? ToObject(this System.Text.Json.JsonElement element) where T : OAuthUser { var user = new OAuthUser(); @@ -69,7 +68,6 @@ namespace Bootstrap.DataAccess ret = property.Value.ToString(); return ret; } -#endif /// /// 插入 Gitee 授权用户到数据库中 diff --git a/src/admin/Bootstrap.DataAccess/Helper/WeChatHelper.cs b/src/admin/Bootstrap.DataAccess/Helper/WeChatHelper.cs index f3f2439f..fac236da 100644 --- a/src/admin/Bootstrap.DataAccess/Helper/WeChatHelper.cs +++ b/src/admin/Bootstrap.DataAccess/Helper/WeChatHelper.cs @@ -4,9 +4,7 @@ using Longbow.WeChatAuth; using Microsoft.AspNetCore.Authentication.OAuth; using System; using System.Linq; -#if NETCOREAPP3_0 using System.Text.Json; -#endif namespace Bootstrap.DataAccess { @@ -55,7 +53,6 @@ namespace Bootstrap.DataAccess }; } -#if NETCOREAPP3_0 private static T? ToObject(this JsonElement element) where T : WeChatUser { var user = new WeChatUser(); @@ -80,6 +77,5 @@ namespace Bootstrap.DataAccess ret = property.Value.ToString(); return ret; } -#endif } } diff --git a/src/client/Bootstrap.Client.DataAccess.MongoDB/Bootstrap.Client.DataAccess.MongoDB.csproj b/src/client/Bootstrap.Client.DataAccess.MongoDB/Bootstrap.Client.DataAccess.MongoDB.csproj index c1c1402f..42c6d4cb 100644 --- a/src/client/Bootstrap.Client.DataAccess.MongoDB/Bootstrap.Client.DataAccess.MongoDB.csproj +++ b/src/client/Bootstrap.Client.DataAccess.MongoDB/Bootstrap.Client.DataAccess.MongoDB.csproj @@ -1,11 +1,11 @@  - netcoreapp3.0 + netcoreapp3.1 - + diff --git a/src/client/Bootstrap.Client.DataAccess/Bootstrap.Client.DataAccess.csproj b/src/client/Bootstrap.Client.DataAccess/Bootstrap.Client.DataAccess.csproj index 960bd8db..6036f5a2 100644 --- a/src/client/Bootstrap.Client.DataAccess/Bootstrap.Client.DataAccess.csproj +++ b/src/client/Bootstrap.Client.DataAccess/Bootstrap.Client.DataAccess.csproj @@ -1,17 +1,17 @@  - netcoreapp3.0 + netcoreapp3.1 - - - - - - - + + + + + + + diff --git a/src/client/Bootstrap.Client/Bootstrap.Client.csproj b/src/client/Bootstrap.Client/Bootstrap.Client.csproj index bd8ffbc9..b0340192 100644 --- a/src/client/Bootstrap.Client/Bootstrap.Client.csproj +++ b/src/client/Bootstrap.Client/Bootstrap.Client.csproj @@ -1,13 +1,13 @@  - netcoreapp3.0 + netcoreapp3.1 true - - + + diff --git a/test/UnitTest/UnitTest.csproj b/test/UnitTest/UnitTest.csproj index ed195a08..21672c48 100644 --- a/test/UnitTest/UnitTest.csproj +++ b/test/UnitTest/UnitTest.csproj @@ -1,7 +1,7 @@  - netcoreapp3.0 + netcoreapp3.1 false full @@ -15,8 +15,8 @@ all runtime; build; native; contentfiles; analyzers; buildtransitive - - + +