How to make depends_on but OR instead of AND

I’d like to run a step if any one of two other steps is completed successfully. Is this possible currently? It seems like depends_on only accepts a list and executes the step if they all pass, and I think if can only use build level information, not step level.

Alternately, since one of these steps is a block step, if I could unblock that within the other step, I think that would also achieve what I want to do. I considered using the API to achieve this, but I’d prefer not to implement such a complicated solution.

Hi @emmasimon! :wave:

Welcome to the community! :blush:
You can achieve that with a wait step and also with a block step. The first one is dependent on all previous steps completing successfully; it won’t proceed until all steps before it have passed. All steps following the wait step are dependent on the wait step; none of them will run until the wait step is satisfied. For example:

steps:
  - command: "one.sh"
  - command: "two.sh"
  - wait
  - command: "three.sh"
  - command: "four.sh"

Block step perform the same function, but also require unblocking either manually or via an API call before the rest of the steps can be run (like you mentioned).

Hope this helps!

Cheers,