Understanding branches in CodeScan Cloud
Last updated
Last updated
Branches allow you to keep track of changes that may affect the branch to which your project is linked. There are two types of branches:
Long lived branches allow you to see the entire dashboard and history of your project.
Short lived branches allow you to see the delta in issues between your branch and your master/production/target.
When creating an analysis project from GitHub or Bitbucket repository in CodeScanCloud, you will be asked to choose the branch to which the project is linked. This branch will become your main branch. If you also select Check Pull requests, any changes that affect this main branch will be reflected in the project with the branch functionality.
If you have set your main branch to master, any relevant pull request will be analyzed when it is created and updated every time. The results will be displayed on the same page as your main branch analysis under the branches’ dropdown menu.
This topic is covered in a separate article. Click here to go to the related article.
When a pull request is created in a VSTS repository or a repository tracked by your VSTS Build Definition, a new branch will be created on your CodeScan Cloud project. Please note that any remote repositories must have Continuous Integration and Pull Request Validation checked for the appropriate branches in the Build Definition’s Triggers menu.
On your Project Analysis page, go to Project Setting > Branches and Pull requests. This page allows users to delete any new branches and also change the branch that the Analysis Project is checking.
Here you can see the branch has four new violations. If the branch is selected, the details of the violation(s) can be seen. All new branches added in this way will be deleted in 30 days if they are not analyzed.
If you have any further questions about CodeScan Cloud, please contact us.
Delete Branch: To delete a branch, click the () button next to the branch and click Delete Branch.
Rename Branch: To change the branch that the Analysis Project is tracking, click the () icon next to the main branch and click Rename Branch. Enter the name of the branch you would like to begin tracking. Changes will only be reflected on the project’s Overview page once the analysis has been performed.