Skip to content

Commit 5aa62d4

Browse files
committed
ci: update build.ps1
1 parent 8aa23d5 commit 5aa62d4

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

build.ps1

+3-2
Original file line numberDiff line numberDiff line change
@@ -15,9 +15,10 @@ if ($isLinux) {
1515
}
1616
} else {
1717
$prNumber = $env:APPVEYOR_PULL_REQUEST_NUMBER
18-
if ($prNumber)
19-
{
18+
if ($prNumber) {
2019
$prArgs = -d:sonar.pullrequest.key=$prNumber
20+
} elseif ($env:APPVEYOR_REPO_BRANCH) {
21+
$prArgs = -d:sonar.branch.name=$env:APPVEYOR_REPO_BRANCH
2122
}
2223
dotnet sonarscanner begin /k:aguacongas_DymamicAuthProviders -o:aguacongas -d:sonar.host.url=https://sonarcloud.io -d:sonar.login=$env:sonarqube -d:sonar.coverageReportPaths=coverage\SonarQube.xml $prArgs -v:$env:Version
2324

0 commit comments

Comments
 (0)