Want to set the the branch for the deployment section in circle.yml

circle.yml

#1

Hi,

Is there any way in which I can pass the branch as a dyanamic variable to circle.yml.

example:

suppose I want to deploy a ‘random_new’ branch to server if all test are green how can I achive that in circle.yml

deployment:
  staging: 
    branch: $dynamic_branch || master
    commands:
      - curl -X POST https://hooks.cloud66.com/stacks/redeploy/my_cloud_redeploy_url

#2