From 3b17ce0ee7bf162872e5486e8e1c9917850c9b91 Mon Sep 17 00:00:00 2001 From: Dominique Louis Date: Fri, 25 Aug 2023 18:03:17 +0100 Subject: [PATCH] Add version replacement for *.Classic projects. --- .github/workflows/dotnet.yml | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/.github/workflows/dotnet.yml b/.github/workflows/dotnet.yml index 20e01a35..3871626e 100644 --- a/.github/workflows/dotnet.yml +++ b/.github/workflows/dotnet.yml @@ -36,8 +36,7 @@ jobs: - name: Setup NuGet uses: NuGet/setup-nuget@v1.0.5 - - if: ${{ github.event_name == 'workflow_dispatch' }} - name: Update CLI Version Numbers + - name: Update CLI Version Numbers run: | $content = Get-Content main/Meadow.CLI/Meadow.CLI.csproj | Out-String $newcontent = $content -replace '.*', '${{ ENV.CLI_RELEASE_VERSION }}' @@ -59,6 +58,14 @@ jobs: $newcontent = $content -replace 'CLI_VERSION = \".*\";', 'CLI_VERSION = "${{ ENV.CLI_RELEASE_VERSION }}";' $newcontent | Set-Content main/Meadow.CLI.Core/Constants.cs + $content = Get-Content main/Meadow.CLI/Meadow.CLI.Classic.csproj | Out-String + $newcontent = $content -replace '.*', '${{ ENV.CLI_RELEASE_VERSION }}' + $newcontent | Set-Content main/Meadow.CLI/Meadow.CLI.Classic.csproj + + $content = Get-Content main/Meadow.CLI.Core/Meadow.CLI.Core.Classic.csproj | Out-String + $newcontent = $content -replace '.*', '${{ ENV.CLI_RELEASE_VERSION }}' + $newcontent | Set-Content main/Meadow.CLI.Core/Meadow.CLI.Core.Classic.csproj + - name: Add MSBuild to Path uses: microsoft/setup-msbuild@v1.1