Where does the Branch setting, in a yml file, get used in the Build Pipeline?

Pure Krome's Avatar

Pure Krome

12 Oct, 2015 03:21 AM

Hi :)

a yml file can have this setting:

branches:
  only:
    - master

where does this setting get used during the Build Pipeline .. especially compared to the GUI setting. Or are -both- used?

  1. Support Staff 1 Posted by Feodor Fitsner on 12 Oct, 2015 06:48 PM

    Feodor Fitsner's Avatar

    It's before the pipeline starts. The setting in appveyor.yml overrides UI.

  2. 2 Posted by Pure Krome on 12 Oct, 2015 09:33 PM

    Pure Krome's Avatar

    If it's before the pipeline starts, how does AV know if the project should be fired off, because the branch info is inside the yml file, which has yet to be downloaded ??

  3. Support Staff 3 Posted by Feodor Fitsner on 12 Oct, 2015 10:22 PM

    Feodor Fitsner's Avatar

    Ah, appveyor.yml is being downloaded using GitHub API ;)

  4. 4 Posted by Pure Krome on 12 Oct, 2015 11:54 PM

    Pure Krome's Avatar

    ?? i don't get it?

    So how does AV know which project to actually activate/fire off .. is this some webhook magic?

    eg.

    • Project1 (GUI: any branch except master)
    • Project2 (yml file: any branch except master)
    • Project3 (yml file: only master branch).

    Imagine i have 3 AV projects that all reference the GitHub repo: someUser/Foo. I then commit to this repo .. to the branch Feature/PewPew.

    What happens now?

    How does AV only know to run Project2 and Project3 ? the branch info is inside the yml...

    I guess my curiosity is killing me :)

  5. Support Staff 5 Posted by Feodor Fitsner on 13 Oct, 2015 05:33 PM

    Feodor Fitsner's Avatar

    Yeah, there is a webhook for each project added to the repo.

    You push changes to the repo. All three webhooks are triggered. AppVeyor downloads appveyor.yml for each project and using branch name from webhook payload finds required configuration to decide whether build should be started or not.

  6. 6 Posted by Pure Krome on 13 Oct, 2015 10:06 PM

    Pure Krome's Avatar

    AH! Ding! Gotcha now :) So there's some invisible pre-build magic that happens before any build starts ... which is why we don't see any output anywhere.

    Excellent! Thanks Feodor!

  7. Pure Krome closed this discussion on 13 Oct, 2015 10:06 PM.

Comments are currently closed for this discussion. You can start a new one.

Keyboard shortcuts

Generic

? Show this help
ESC Blurs the current field

Comment Form

r Focus the comment reply box
^ + ↩ Submit the comment

You can use Command ⌘ instead of Control ^ on Mac