Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
87 changes: 0 additions & 87 deletions Activities/.pipelines/SONARCLOUD_ADMIN_CHECKLIST.md

This file was deleted.

4 changes: 2 additions & 2 deletions Activities/.pipelines/templates/stage.build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ jobs:
projectKey: ${{ parameters.sonarProjectKey }}
serviceConnectionName: ${{ parameters.sonarServiceConnection }}
organization: ${{ parameters.sonarOrganization }}
condition: and(eq(variables['RunAnalysis'], 'true'), ne(variables['System.PullRequest.IsFork'], 'True'), ne(variables['Build.Reason'], 'PullRequest'), not(startsWith(variables['Build.SourceBranch'], 'refs/heads/masters/')), not(startsWith(variables['Build.SourceBranch'], 'refs/heads/support/')))
condition: and(eq(variables['RunAnalysis'], 'true'), ne(variables['System.PullRequest.IsFork'], 'True'), not(startsWith(variables['Build.SourceBranch'], 'refs/heads/masters/')), not(startsWith(variables['Build.SourceBranch'], 'refs/heads/support/')))
postBuild:
- ${{ parameters.postBuild }}

Expand All @@ -58,7 +58,7 @@ jobs:

- template: Sonar/upload-sonar-build-output.yml
parameters:
condition: and(eq(variables['RunAnalysis'], 'true'), ne(variables['System.PullRequest.IsFork'], 'True'), ne(variables['Build.Reason'], 'PullRequest'), not(startsWith(variables['Build.SourceBranch'], 'refs/heads/masters/')), not(startsWith(variables['Build.SourceBranch'], 'refs/heads/support/')))
condition: and(eq(variables['RunAnalysis'], 'true'), ne(variables['System.PullRequest.IsFork'], 'True'), not(startsWith(variables['Build.SourceBranch'], 'refs/heads/masters/')), not(startsWith(variables['Build.SourceBranch'], 'refs/heads/support/')))

- template: Sonar/uninstall-sonar-targets.yml

Expand Down
14 changes: 3 additions & 11 deletions Activities/.pipelines/templates/stage.start.yml
Original file line number Diff line number Diff line change
Expand Up @@ -87,17 +87,9 @@ stages:
- Test
- ${{ each stage in parameters.sonarDependsOn }}:
- ${{ stage }}
# Sonar runs only on develop and release/* pushes — never on masters/* or
# support/* (the two startsWith exclusions below), and not on PR triggers until
# SonarCloud's main branch is renamed from master (stale, 6 years) to develop.
# See SONARCLOUD_ADMIN_CHECKLIST.md.
# When restoring PR decoration after the rename: remove ONLY the
# `ne(variables['Build.Reason'], 'PullRequest')` clause. Keep the IsFork clause
# (guards out fork PRs, where AzDO strips secrets and Sonar would fail anyway)
# and the masters/support exclusions (PR builds use refs/pull/* so the
# exclusions don't block them). The same guards appear on the prepare/upload
# condition parameters in stage.build.yml.
condition: and(not(canceled()), eq(variables['RunAnalysis'], 'true'), eq(stageDependencies.Build.outputs['DetermineShouldRun.SetRunVariable.BuildShouldRun'], 'true'), ne(variables['System.PullRequest.IsFork'], 'True'), ne(variables['Build.Reason'], 'PullRequest'), not(startsWith(variables['Build.SourceBranch'], 'refs/heads/masters/')), not(startsWith(variables['Build.SourceBranch'], 'refs/heads/support/')))
# IsFork blocks fork PRs (AzDO strips secrets); masters/* and support/* exclusions
# guard against direct pushes — PR builds use refs/pull/* so they aren't affected.
condition: and(not(canceled()), eq(variables['RunAnalysis'], 'true'), eq(stageDependencies.Build.outputs['DetermineShouldRun.SetRunVariable.BuildShouldRun'], 'true'), ne(variables['System.PullRequest.IsFork'], 'True'), not(startsWith(variables['Build.SourceBranch'], 'refs/heads/masters/')), not(startsWith(variables['Build.SourceBranch'], 'refs/heads/support/')))
jobs:
- template: stage.sonar.yml
parameters:
Expand Down