I have 2 repositories in 1 plan where repo1 is the default repo and repo2 is non default. The way Bamboo plans work is the default repo is able to checkout to specific branches, but the non-default can only checkout to master. I am trying find a way around this so that I can pass in a plan variable to repo2 that sets it to what branch I want.This is what I've experimented with so far:
1. Added a plan variable
I override this on a manual build

2. Passed in the plan variable into the script
$bamboo_planRepository_2_branch
this tells you branch info when you echo it out.
So I tried doing this but didn't work:

What is the correct way to override build-specific variables in Bamboo?