From 289da6fca4058fc1689a06b059820b9265cd4f31 Mon Sep 17 00:00:00 2001 From: real-zony Date: Tue, 12 Dec 2023 10:41:28 +0800 Subject: [PATCH] ci: Fixed the error where the Shell script could not find the path. --- .gitignore | 4 +++- scripts/build.sh | 6 +++--- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/.gitignore b/.gitignore index 20a765a..4619a97 100644 --- a/.gitignore +++ b/.gitignore @@ -17,4 +17,6 @@ AliCloudDynamicDNS/settings.json AliCloudDynamicDNS/release/AliCloudDynamicDNS.exe AliCloudDynamicDNS/release/AliCloudDynamicDNS.pdb -/AliCloudDynamicDNS/TempFiles \ No newline at end of file +/AliCloudDynamicDNS/TempFiles + +TempFiles/ \ No newline at end of file diff --git a/scripts/build.sh b/scripts/build.sh index a4efd31..2d0ec3d 100755 --- a/scripts/build.sh +++ b/scripts/build.sh @@ -14,7 +14,7 @@ fi rm -rf ./TempFiles/* for platform in "${Platforms[@]}"; do - dotnet publish -r "$platform" -c Release -p:PublishSingleFile=true -p:PublishTrimmed=true --self-contained true -p:PublishWithAspNetCoreTargetManifest=false - zip -r -j "./bin/Release/net$DOTNET_VERSION/$platform/publish/${PROGRAM_NAME}_${platform}_$RELEASE_VERSION.zip" "./bin/Release/net$DOTNET_VERSION/$platform/publish/"* - mv "./bin/Release/net$DOTNET_VERSION/$platform/publish/${PROGRAM_NAME}_${platform}_$RELEASE_VERSION.zip" ./TempFiles + dotnet publish -r "$platform" -c Release -p:PublishSingleFile=true -p:PublishTrimmed=true --self-contained true /p:useapphost=true -p:PublishWithAspNetCoreTargetManifest=false + zip -r -j "./AliCloudDynamicDNS/bin/Release/net$DOTNET_VERSION/$platform/publish/${PROGRAM_NAME}_${platform}_$RELEASE_VERSION.zip" "./AliCloudDynamicDNS/bin/Release/net$DOTNET_VERSION/$platform/publish/"* + mv "./AliCloudDynamicDNS/bin/Release/net$DOTNET_VERSION/$platform/publish/${PROGRAM_NAME}_${platform}_$RELEASE_VERSION.zip" ./TempFiles done