But for each one I want to do conditional setup steps based on the executor type and I couldn’t find a way to do that.
I tried:
condition:
equal: [ macos, << parameters.os >> ]
but the condition is never true as << paramaters.os >> seems to be converted into an executor object string and so it is not the same as macos even when the executor type is called macos.
In the above, I am defining three executors, “linux”, “mac”, and “windows”.
Then I set the executor for the job to equal the name of the executor being passed in by the pipeline variable “os”. This will run the job test for each executor named in the matrix.
For more information regarding executors and conditional workflows, please take a look at the following sections in our documentation: