My current implementation of Azure pipelines is to trigger only when a pull request is made to Develop branch. But, I want to run the pipeline on every new push on any branch. How to trigger that?
My current implementation of the Azure YAML file
trigger:
- none
pr:
- branches:
include:
- dev
and below that steps are configured.
Select trigger: Set the trigger that will start the deployment to this stage automatically. Select "Release" to deploy to the stage every time a new release is created. Use the "Stage" option to deploy after deployments to selected stages are successful. To allow only manual deployments, select "Manual".
You can set up pull request triggers for both Azure Repos or GitHub repositories. From within your project, Select Pipelines > Releases, and then select your release pipeline. Under the Pull request trigger section, select the toggle button to enable it.
You need to specify the trigger something like this. So for example, if there is anything pushed in dev
branch a build will get triggered. Ref
trigger:
- dev
or to be more explicit:
trigger:
branches:
include:
- dev
- another-branch
If no triggers are specified it will by default run for all branches. It can be explicitly defined as:
trigger:
branches:
include:
- '*'
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With