I want to conditionally checkout branch B if unable to checkout branch A (e.g. it doesn't exist).
- checkout: self
- checkout: git://stackoverflow/_git/MuhRepo@A
continueOnError: true
- checkout: git://stackoverflow/_git/MuhRepo@B
condition: failed()
Unfortunately, rather than running through the pipeline is blocked with:
This pipeline is not valid. Could not get the latest source version for repository MuhRepo hosted on Azure Repos using ref refs/head/A
I would rather avoid calling a bash script that does the git stuff for me as it would seem against the spirit of devops.
Any advice appreciated!