[Feature request] run deployment steps with event filter

Hi there!

Just look at this please:

pipeline:

  some-step-one:
    image: debian:buster
    commands:
      - curl hostA
    when:
      environment: ci
      event: step1

  some-step-two:
    image: debian:buster
    commands:
      - curl hostB
    when:
      environment: ci
      event: step2

As simple as that. I want to have some steps in my pipeline, which are only user-triggered.
As far as i understand, only deploy logic can help me.

I’d like to be able to do just this:

drone deploy myrepo/myproject 12 ci --event step2

After that, only some-step-two block is activated.

But it ain’t going to work ATM, since i have to include deployment event to step one/two blocks, so deployment will work. But after that all steps gonna be triggered, since event would be deployment, not step2 ( as seen in env vars).

Please, help me with this, some actions are still needed to be done separately, and for people coming from jenkins/teamcity this flow could be helpful, since we can bring power of oauth+secret management to simple actions.

Thanks a lot in advance!

Right now the only way is to use custom environment for everything, which really doesn’t seem right.

pipeline:

  some-step-one:
    image: debian:buster
    commands:
      - curl hostA
    when:
      environment: ci-step1

  some-step-two:
    image: debian:buster
    commands:
      - curl hostB
    when:
      environment: ci-step2