diff --git a/build/build.csproj b/build/build.csproj index 3a094517c..d6c24a188 100644 --- a/build/build.csproj +++ b/build/build.csproj @@ -139,8 +139,6 @@ - - diff --git a/build/stage-build-android-mobile.yml b/build/stage-build-android-mobile.yml index 2bd936751..2324f03bb 100644 --- a/build/stage-build-android-mobile.yml +++ b/build/stage-build-android-mobile.yml @@ -17,13 +17,13 @@ steps: cd $(build.sourcesdirectory)/Uno.Gallery dotnet publish -f:net9.0-android -p:TargetFrameworkOverride=net9.0-android -c:Release "/p:InformationalVersion=$(GitVersion.InformationalVersion)" /p:AndroidSigningKeyStore=$(keyStore.secureFilePath) /p:AndroidSigningStorePass=$(AndroidSigningStorePass) /p:AndroidSigningKeyPass=$(AndroidSigningKeyPass) /p:AndroidSigningKeyAlias=$(AndroidSigningKeyAlias) /p:AndroidKeyStore=true /bl:$(build.artifactstagingdirectory)/build-$(BuildForPlayStore).binlog displayName: 'Build Android Package' - condition: eq(variables['System.PullRequest.IsFork'],'False') + condition: and(suceeded(), eq(variables['System.PullRequest.IsFork'],'False')) - script: | cd $(build.sourcesdirectory)/Uno.Gallery dotnet publish -f:net9.0-android -p:TargetFrameworkOverride=net9.0-android -c:Release "/p:InformationalVersion=$(GitVersion.InformationalVersion)" /p:AndroidKeyStore=False /bl:$(build.artifactstagingdirectory)/build-$(BuildForPlayStore).binlog displayName: 'Build Android Package (Fork)' - condition: eq(variables['System.PullRequest.IsFork'],'True') + condition: and(suceeded(), eq(variables['System.PullRequest.IsFork'],'True')) - task: CopyFiles@2 displayName: 'Publish Android netcore Binaries' diff --git a/build/stage-build-mobile.yml b/build/stage-build-mobile.yml index 76b93a3ea..419a34a0f 100644 --- a/build/stage-build-mobile.yml +++ b/build/stage-build-mobile.yml @@ -16,7 +16,7 @@ steps: secureFile: nventive.jks - task: UseDotNet@2 - condition: eq(variables['IsCanaryBranch'], true) + condition: and(suceeded(), eq(variables['IsCanaryBranch'], true)) retryCountOnTaskFailure: 3 inputs: packageType: runtime @@ -29,14 +29,14 @@ steps: echo "BUILD_SOURCEBRANCH: $BUILD_SOURCEBRANCH" dotnet $(BuildCommand) -v:n -f $(BuildTargetFramework) -p:TargetFrameworkOverride=$(BuildTargetFramework) -c Release /p:ArchiveOnBuild=true /bl:$(build.artifactstagingdirectory)/build-$(BuildTargetFramework).binlog "/p:InformationalVersion=$(GitVersion.InformationalVersion)" displayName: Build project for Release - $(BuildTargetFramework) - condition: eq(variables['System.PullRequest.IsFork'],'False') + condition: and(suceeded(), eq(variables['System.PullRequest.IsFork'],'False')) - bash: | cd $(build.sourcesdirectory)/Uno.Gallery echo "BUILD_SOURCEBRANCH: $BUILD_SOURCEBRANCH" dotnet build -f $(BuildTargetFramework) -p:TargetFrameworkOverride=$(BuildTargetFramework) -c Release /bl:$(build.artifactstagingdirectory)/build-$(BuildTargetFramework).binlog "/p:InformationalVersion=$(GitVersion.InformationalVersion)" displayName: Build project for Release - $(BuildTargetFramework) - condition: eq(variables['System.PullRequest.IsFork'],'True') + condition: and(suceeded(), eq(variables['System.PullRequest.IsFork'],'True')) - task: CopyFiles@2 displayName: 'Publish Binaries' diff --git a/build/templates/dotnet-install-linux.yml b/build/templates/dotnet-install-linux.yml index abb300b2c..54e9c81be 100644 --- a/build/templates/dotnet-install-linux.yml +++ b/build/templates/dotnet-install-linux.yml @@ -24,10 +24,10 @@ steps: sudo update-java-alternatives --set msopenjdk-11-amd64 displayName: Install OpenJDK 11 retryCountOnTaskFailure: 3 - condition: eq('${{ parameters.installJava }}', 'true') + condition: and(suceeded(), eq('${{ parameters.installJava }}', 'true')) - bash: | dotnet tool update --global uno.check --version ${{ parameters.UnoCheck_Version }} --add-source https://api.nuget.org/v3/index.json uno-check --verbose --ci --non-interactive --fix --skip gtk3 --skip androidsdk --pre-major ${{ parameters.UnoCheckParameters }} displayName: Install .NET Workloads - condition: and( eq(variables['Agent.OS'], 'Linux'), eq('${{ parameters.installWorkloads }}', 'true') ) + condition: and(suceeded(), and( eq(variables['Agent.OS'], 'Linux'), eq('${{ parameters.installWorkloads }}', 'true') )) diff --git a/build/templates/dotnet-install-mac.yml b/build/templates/dotnet-install-mac.yml index e1e128d99..eea34d76a 100644 --- a/build/templates/dotnet-install-mac.yml +++ b/build/templates/dotnet-install-mac.yml @@ -31,4 +31,4 @@ steps: dotnet tool update --global uno.check --version ${{ parameters.UnoCheck_Version }} --add-source https://api.nuget.org/v3/index.json uno-check --ci --non-interactive --fix --skip gtk3 --skip xcode --skip vswin --skip androidemulator --skip vsmac --pre-major ${{ parameters.UnoCheckParameters }} displayName: Install .NET Workloads - condition: and( eq(variables['Agent.OS'], 'Darwin'), eq('${{ parameters.installWorkloads }}', 'true') ) + condition: and(suceeded(), and( eq(variables['Agent.OS'], 'Darwin'), eq('${{ parameters.installWorkloads }}', 'true') )) diff --git a/build/templates/dotnet-install-windows.yml b/build/templates/dotnet-install-windows.yml index b791162da..4811ab18f 100644 --- a/build/templates/dotnet-install-windows.yml +++ b/build/templates/dotnet-install-windows.yml @@ -31,4 +31,4 @@ steps: errorActionPreference: continue ignoreLASTEXITCODE: true retryCountOnTaskFailure: 3 - condition: eq(variables['Agent.OS'], 'Windows_NT') + condition: and(suceeded(), eq(variables['Agent.OS'], 'Windows_NT'))