Except `gh-pages` branch

Yury's Avatar


21 Mar, 2018 10:18 PM

First of all, I would like to apologize in advance if my question is foolish, I'm a newcomer to CI and all this stuff.

I wanted to configure multiple per-branch configurations in that way:
* just a regular build for all branches except master
* release build for master branch and publish artifacts
* don't build gh-pages branch at all

I used this manual and managed to create appveyor.yml which satisfying first two conditions - link to github file.

Unfortunately, the third condition is unfulfilled - gh-pages branch still building - this build for instance.

I have found this line: gh-pages branch is always excluded unless explicitly added in “only” list. in doc and check one more time that I don't have this branch in "only" list.

I've found that build script is different from my setup in appveyor.yml, so then I thought that something wrong in regular settings (on site) and try to add gh-pages branch to excluded there: except
but the branch still builds.

Thank you in advance!

  1. 1 Posted by Ilya Finkelshte... on 21 Mar, 2018 11:24 PM

    Ilya Finkelshteyn's Avatar

    No need to apologize, this part is really complicated :) gh-pages excluded if you have branch filtering. But in your configuration there are multiple configuration, and not branch filtering. UI settings from screenshot does not apply as YAML takes over UI.

    Please try this YAML. It has default config for all branches, special one for master and gh-pages are filtered out.

    version: 1.0.{build}
    image: Visual Studio 2017
      - gh-pages
      - pwsh: dotnet --version
      - pwsh: dotnet build ./src/CityMap.csproj -c Release
        - master
        - pwsh: dotnet build ./src/CityMap.csproj -c Release
        - pwsh: dotnet publish ./src/CityMap.csproj -c Release -r win10-x64
        - pwsh: dotnet publish ./src/CityMap.csproj -c Release -r linux-x64
        - pwsh: dotnet publish ./src/CityMap.csproj -c Release -r osx-x64    
      - path: 'src\bin\Release\netcoreapp2.0\win10-x64\publish'
        name: win10-x64
      - path: 'src\bin\Release\netcoreapp2.0\linux-x64\publish'
        name: linux-x64
      - path: 'src\bin\Release\netcoreapp2.0\osx-x64\publish'
        name: osx-x64
  2. Ilya Finkelshteyn closed this discussion on 25 Aug, 2018 02:27 AM.

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

Keyboard shortcuts


? 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