I am new to sonarcloud and would like to automate my code quality tests in bitbucket I am trying to use bitbucket pipelines to do it (I am new to pipelines too) my end goal is to do a branch analysis of codes and display the results in the bitbucket UI itself on trying to follow the steps in sonarcloud I came across these lines of codes and I am unclear what to add to allow the automating code check :
image: ************************** # Choose an image matching your project needs
clone: depth: full # SonarCloud scanner needs the full history to assign issues properly
definitions: caches: sonar: ~/.sonar/cache # Caching SonarCloud artifacts will speed up your build steps: - step: &build-test-sonarcloud name: Build, test and analyze on SonarCloud caches: - ************************** # See https://confluence.atlassian.com/bitbucket/caching-dependencies-895552876.html - sonar script: - ************************** # Build your project and run - pipe: sonarsource/sonarcloud-scan:1.2.0 - step: &check-quality-gate-sonarcloud name: Check the Quality Gate on SonarCloud script: - pipe: sonarsource/sonarcloud-quality-gate:0.1.4
pipelines: # More info here: https://confluence.atlassian.com/bitbucket/configure-bitbucket-pipelines-yml-792298910.html branches: master: - step: *build-test-sonarcloud - step: *check-quality-gate-sonarcloud pull-requests: '**': - step: *build-test-sonarcloud - step: *check-quality-gate-sonarcloud