From de4cf876a7be86f938caf0d088b334ddbaac5043 Mon Sep 17 00:00:00 2001 From: Tomasz Walecki Date: Sun, 15 Jan 2023 21:34:58 +0100 Subject: [PATCH] Update github actions --- .github/workflows/android.yml | 8 ++++---- .github/workflows/winui.yml | 2 +- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/.github/workflows/android.yml b/.github/workflows/android.yml index 0cebb2f..9550d78 100644 --- a/.github/workflows/android.yml +++ b/.github/workflows/android.yml @@ -9,6 +9,7 @@ on: input_app_version: description: 'Application version' required: true + type: string default: '1.0.0' jobs: @@ -33,10 +34,10 @@ jobs: - name: Change Version run: | # Get current version code and increment - $manifestPath = 'RacingCarsControllerAndroid/AndroidManifest.xml' + $manifestPath = "$env:Project_Directory/AndroidManifest.xml" + $csprojPath = $env:Project_Path $newVersionCode = git rev-list HEAD --count $newVersionName = ${{ inputs.input_app_version }} - $csprojPath = $env:Project_Path # Update manifest (Get-Content $manifestPath) -Replace 'android:versionCode="\d+"', "android:versionCode=`"${newVersionCode}`"" | Set-Content $manifestPath @@ -46,7 +47,6 @@ jobs: (Get-Content $csprojPath) -Replace '\d+', "$newVersionCode" | Set-Content $csprojPath (Get-Content $csprojPath) -Replace '[\w\d.-]+', "$newVersionName" | Set-Content $csprojPath - Write-Host "New versionName: $newVersionName, new versionCode: $newVersionCode" - name: Setup .NET 7 uses: actions/setup-dotnet@v2 @@ -88,7 +88,7 @@ jobs: - name: Create a GitHub release uses: ncipollo/release-action@v1 with: - tag: ${{ inputs.input_app_version }} + tag: android-v${{ inputs.input_app_version }} name: Release Android ${{ inputs.input_app_version }} artifacts: "./*.apk" generateReleaseNotes: true diff --git a/.github/workflows/winui.yml b/.github/workflows/winui.yml index 4074371..fb7bd0a 100644 --- a/.github/workflows/winui.yml +++ b/.github/workflows/winui.yml @@ -135,7 +135,7 @@ jobs: uses: ncipollo/release-action@v1 if: matrix.ChannelName == 'Prod_Sideload' with: - tag: ${{ env.App_Version }} + tag: desktop-v${{ env.App_Version }} name: Release Desktop ${{ env.App_Version }} artifacts: "./*.msix,./*.cer" generateReleaseNotes: true