From 9abf222822e6ff9075fa3fcfb21c9faa64078f0c Mon Sep 17 00:00:00 2001 From: NaBian <836904362@qq.com> Date: Sun, 24 Mar 2024 11:49:48 +0800 Subject: [PATCH] chore: update build.yml. --- .github/workflows/build.yml | 10 +++++++--- .github/workflows/bump-up-version.yml | 2 +- build/build.cake | 11 +++++++---- build/build.config.xml | 4 ++-- 4 files changed, 17 insertions(+), 10 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 042156d3b..bc7401689 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -1,3 +1,5 @@ +name: Build + on: [push, pull_request] jobs: @@ -14,7 +16,9 @@ jobs: include-prerelease: true - name: Build - shell: pwsh + working-directory: ./build run: | - cd build - .\build.ps1 + dotnet new tool-manifest + dotnet tool install cake.tool --version 4.0.0 + dotnet tool install minver-cli --version 3.0.0 + dotnet cake diff --git a/.github/workflows/bump-up-version.yml b/.github/workflows/bump-up-version.yml index dec881604..dfe4bc6f9 100644 --- a/.github/workflows/bump-up-version.yml +++ b/.github/workflows/bump-up-version.yml @@ -24,7 +24,7 @@ jobs: dotnet-version: '8.0.x' include-prerelease: true - - name: Build + - name: Publish working-directory: ./build run: | dotnet new tool-manifest diff --git a/build/build.cake b/build/build.cake index d5c3c79d0..17346f69c 100644 --- a/build/build.cake +++ b/build/build.cake @@ -23,7 +23,7 @@ var target = Argument("target", "build"); var preReleasePhase = Argument("pre-release-phase", "rc"); var preRelease = Argument("pre-release", false); var username = Argument("username", "NaBian"); -var email = Argument("email, "836904362@qq.com"); +var email = Argument("email", "836904362@qq.com"); var libVersion = ""; var nugetVersion = ""; @@ -234,7 +234,7 @@ Task("pack nuspec files") } }); -Task("build") +Task("publish") .IsDependentOn("update license") .IsDependentOn("update version") .IsDependentOn("update copyright") @@ -246,8 +246,11 @@ Task("build") .IsDependentOn("build lib") .IsDependentOn("build demo") .IsDependentOn("create lang nuspec files") - .IsDependentOn("pack nuspec files") - ; + .IsDependentOn("pack nuspec files"); + +Task("build") + .IsDependentOn("build lib") + .IsDependentOn("build demo"); RunTarget(target); diff --git a/build/build.config.xml b/build/build.config.xml index 62ed211a9..d0090c1ec 100644 --- a/build/build.config.xml +++ b/build/build.config.xml @@ -2,7 +2,7 @@ outputs - +