Hi,
I am trying to update the source repository branch in a manually created plan branch using bamboo CLI.
1) I am an admin in the Bamboo Master.
2) I create a plan and added some stages and jobs in it. createPlan
3) I added an existing repository to the plan. addRepository
4) I created a plan branch with its name and description using addBranch
5)) I try to update the plan branch with the chainBranchRepository item being set to a specific branch but none of the arguments are getting updated. updateBranchingOptions
--action createPlan --plan "PROJECT-plan_11" --replace --projectName "PROJECT"
--action addStage --plan @plan@ --stage "SETUP"
--action addJob --plan @plan@ --stage @stage@ --job "SETUP"
--action addRequirement --plan @plan@ --job @Job@ --requirement "SIMULATION"
--action addTask --plan @plan@ --job @Job@ --taskKey "CHECKOUT" --description "setup" --field1 "repository" --value1 ""
--action addRepository --plan @plan@ --name "myrepo" --branch "bugfix/SM-63220-fixing-bamboo-updateBranch-run"
--action addBranch --plan @plan@ --branch "SM-63220" --enable
--action updateBranchingOptions --plan "PROJECT-PLAN11" --field "planBranchCreationmatching_vcs_branch=true" --field "planBranchCreationRegularExpression=bugfix/SM-63220-fixing-bamboo-updateBranch-run"
I have tried multiple ways to update the source repository branch for a branch in a bamboo plan but with no results. I have looked up all the examples for bamboo CLI but there is nothing which helps me to updated the source repository branch for a plan branch.
Kindly provide your help to understand how one can update the source repository-branch for a plan branch.
Hi @Girish ,
Thanks for submitting your question!
We have created SUPPORT-4086 to track the issue. Please access the Support request SUPPORT-4086 and once you signup, please let us know your username so that we can add yourself as the reporter to the support request.
Please let us know the version of Bamboo and the version of Command Line Interface (CLI) which you are using to troubleshoot the issue further.
Thanks,
Reshma
Please find the Bamboo details below
Bamboo version : Version5.15.3
Bob Swift Atlassian Apps - Bamboo Command Line Interface (CLI) version : 9.2.0
Thanks,
Girish
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi @Girish
Hope you are doing great!
We have updated the support request SUPPORT-4086 with the analysis, can you please refer to the details and let us know if you have any further queries.
Looking forward to your response.
Thanks,
Manisha
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi @Girish
We would like to inform you that the Bamboo Command Line Interface (CLI) version 9.2.0 is not supported for the Bamboo version 5.15. We recommend you update the Bamboo version to the latest which is compatible with CLI version 9.2.
Use getBranchingOptions to view the available fields that can be set and then set the field value. After that execute the action updateBranchingOptions for the respective plan.
Before executing the update branch you can add the repository in your Build Plan than the Repository will be added after creating the branch.
Thanks,
Manisha
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Manisha,
I was able to find the solution after I posted the question.
Solution: Is to use the addRepository command with proper branch name. The brnach name should not be containing any spaces or special characters in its name.
--action addRepository --plan @plan@ --name "myrepo" --branch "release/mybranch_name"
Thanks,
Girish
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.