From 1118999b6d6d6d4bd3dcd39213caf695603d7529 Mon Sep 17 00:00:00 2001 From: hzhang Date: Tue, 18 Feb 2025 20:01:28 +0000 Subject: [PATCH] init --- VersionInfo.props | 9 +++++++++ run | 39 +++++++++++++++++++++++++++++++++++++++ 2 files changed, 48 insertions(+) create mode 100644 VersionInfo.props create mode 100644 run diff --git a/VersionInfo.props b/VersionInfo.props new file mode 100644 index 0000000..02ecf64 --- /dev/null +++ b/VersionInfo.props @@ -0,0 +1,9 @@ + + + 4.4.0-beta.3 + 0.1.1-x + 0.1.1-x + 0.1.1-x + 0.0.1 + + \ No newline at end of file diff --git a/run b/run new file mode 100644 index 0000000..774df32 --- /dev/null +++ b/run @@ -0,0 +1,39 @@ +#!/bin/bash +set -e + +PoloniumPath="./Polonium/" +PoloniumTasksPath="./Polonium.Tasks/" +PoloniumGeneratorsPath="./Polonium.Generators/" +PoloniumSdkPath="./Polonium.Sdk/" +VersionInfo="./VersionInfo.props" + +RepoBase="https://git.hangman-lab.top/hzhang/" +Repos=("Polonium" "Polonium.Tasks" "Polonium.Generators" "Polonium.Sdk") +for repo in "${Repos[@]}"; do + if [ -d "./$repo/.git" ]; then + git -C "./$repo" pull + else + git clone "$RepoBase$repo.git" + fi +done + + +rm -f "${PoloniumPath}Package/build/VersionInfo.props" +rm -f "${PoloniumTasksPath}Package/build/VersionInfo.props" +rm -f "${PoloniumGeneratorsPath}VersionInfo.props" +rm -f "${PoloniumSdkPath}Sdk/VersionInfo.props" + +cp "$VersionInfo" "${PoloniumPath}Package/build/VersionInfo.props" +cp "$VersionInfo" "${PoloniumTasksPath}Package/build/VersionInfo.props" +cp "$VersionInfo" "${PoloniumGeneratorsPath}VersionInfo.props" +cp "$VersionInfo" "${PoloniumSdkPath}Sdk/VersionInfo.props" + +rm -rf ~/.nuget/packages/polonium* + +for repo in "${Repos[@]}"; do + dotnet clean "./$repo/$repo.csproj" + dotnet restore "./$repo/$repo.csproj" + dotnet build "./$repo/$repo.csproj" + chmod +x "./$repo/publish" + bash "./$repo/publish" +done \ No newline at end of file