Grzegorz Orda
Grzegorz Orda

Reputation: 33

Azure DevOps Pipeline - wildcard not trigger pipeline

I would like to ask you what is a the reason of not running a pipeline after making a commit from Visual Studio to repository located in Azure DevOps? Has trigger in yaml lower priority from trigger builded inside pipeline where default is set to develop (Yaml -GetSource)?

My current yaml code:

 trigger:
      branches:
        include:
        - feature/*  

Name of my current branch local/origin:

feature/employer-service

Thanks in advance for all answers.

Upvotes: 0

Views: 2135

Answers (2)

Grzegorz Orda
Grzegorz Orda

Reputation: 33

Thank you for your time, I've found solution:

In order to run pipeline after making commit from repository, you have to add separate yaml file to branch which actually you are pushing.

I had yaml file on develop branch but the necessary was to add a similar yaml file with whole setup to a new branch.

Upvotes: 0

Hugh Lin
Hugh Lin

Reputation: 19461

As you found in the comment, if you want the branch to get CI triggers, you need to make sure that the same azure-pipelines.yml file exists on the branch.

You can switch to each branch on the pipeline page to check whether the azure-pipelines.yml file is included. If it does not exist, you will get the following error.

enter image description here

Upvotes: 0

Related Questions