aboutsummaryrefslogtreecommitdiffstats
path: root/sonar-scanner-engine/src/main/java/org/sonar/scanner/scan
diff options
context:
space:
mode:
authorJulien HENRY <julien.henry@sonarsource.com>2018-03-27 11:52:20 +0200
committerSonarTech <sonartech@sonarsource.com>2018-05-16 20:20:46 +0200
commit965717195e58808778753edd0daa0e3d9e831cdd (patch)
treef1aaeebba925cec8366fae5eccfa1f1f08fc11d6 /sonar-scanner-engine/src/main/java/org/sonar/scanner/scan
parent5073eb0f98e99ab0efbdd3f34b07a97f11e1d26c (diff)
downloadsonarqube-965717195e58808778753edd0daa0e3d9e831cdd.tar.gz
sonarqube-965717195e58808778753edd0daa0e3d9e831cdd.zip
Introduce Bitbucket Cloud Application
SONAR-10514 Bitbucket Cloud application install/uninstall * Bitbucket Cloud /install WS * Expose Bitbucket application descriptor as WS * Implement WS /integration/bitbucketcloud/uninstall SONAR-10517 Bitbucket Cloud settings widget * Create Bitbucket Cloud module * Create Bitbucket Setting widget * Bitbucket settings widget require SC authentication * Add WS /integration/bitbucketcloud/repo_config * Add WS /integration/bitbucketcloud/bind_repo * Add WS /integration/bitbucketcloud/after_login SONAR-10516 Bitbucket Cloud repository widget * Add WS /integration/bitbucketcloud/repo_widget * Add WS /integration/bitbucketcloud/repo_widget_data BRANCH-59, BRANCH-60 Bitbucket Cloud PR decoration SONAR-10605 Bitbucket Cloud PR widget * Add integration/bitbucketcloud/pr_widget endpoint * Add integration/bitbucketcloud/pr_widget_data endpoint
Diffstat (limited to 'sonar-scanner-engine/src/main/java/org/sonar/scanner/scan')
-rw-r--r--sonar-scanner-engine/src/main/java/org/sonar/scanner/scan/ProjectScanContainer.java15
1 files changed, 5 insertions, 10 deletions
diff --git a/sonar-scanner-engine/src/main/java/org/sonar/scanner/scan/ProjectScanContainer.java b/sonar-scanner-engine/src/main/java/org/sonar/scanner/scan/ProjectScanContainer.java
index 59d8e6b8846..c81845047b1 100644
--- a/sonar-scanner-engine/src/main/java/org/sonar/scanner/scan/ProjectScanContainer.java
+++ b/sonar-scanner-engine/src/main/java/org/sonar/scanner/scan/ProjectScanContainer.java
@@ -258,16 +258,11 @@ public class ProjectScanContainer extends ComponentContainer {
ScannerProperties.BRANCH_NAME, ScannerProperties.BRANCHES_DOC_LINK);
}
- String branchName = props.property(ScannerProperties.BRANCH_NAME);
- if (branchName != null) {
- BranchConfiguration branchConfig = getComponentByType(BranchConfiguration.class);
- LOG.info("Branch name: {}, type: {}", branchName, branchTypeToDisplayName(branchConfig.branchType()));
- }
-
- String pullRequestBranch = props.property(ScannerProperties.PULL_REQUEST_BRANCH);
- if (pullRequestBranch != null) {
- String pullRequestBase = props.property(ScannerProperties.PULL_REQUEST_BASE);
- LOG.info("Pull request into {}: {}", pullRequestBaseToDisplayName(pullRequestBase), pullRequestBranch);
+ BranchConfiguration branchConfig = getComponentByType(BranchConfiguration.class);
+ if (branchConfig.branchType() == BranchType.PULL_REQUEST) {
+ LOG.info("Pull request {} for merge into {} from {}", branchConfig.pullRequestKey(), pullRequestBaseToDisplayName(branchConfig.branchBase()), branchConfig.branchName());
+ } else if (branchConfig.branchName() != null) {
+ LOG.info("Branch name: {}, type: {}", branchConfig.branchName(), branchTypeToDisplayName(branchConfig.branchType()));
}
LOG.debug("Start recursive analysis of project modules");