0

I have a azure-pipeline-pr.yaml file in this format which uses the GitHub repository.

pr:
  branches:
    include:
    - dev2
    - master
  paths:
    exclude:
    - README.md
    - /README.md
    
    
stages:
- stage: PR
  condition: eq(variables['Build.Reason'], 'PullRequest')
  displayName: prb
  jobs:

Directory Structure

app1>
  -azure-pipeline-pr.yml
  - README.md
  - src(folder)

The pr build is triggering correctly. I have raised a PR from featurex to dev2 branch and a pr build is generated.

I have not closed the above PR and I make a change to the README.md file which I have excluded in the paths:. The PR build is again getting triggered.

Can anyone please tell me what is the mistake here?

Ismaili Mohamedi
  • 906
  • 7
  • 15
Coder
  • 39
  • 6

1 Answers1

0

Normally the pipeline starts from the repository construction, but sometimes it is advisable to check all directories to avoid path errors.

  branches:
    include:
    - dev2
    - master
  paths:
    include:
    - '*'
    exclude:
    - '**/README.md'

Please let me know if this could help.

Kai W
  • 119
  • 11