# SPDX-License-Identifier: GPL-2.0-or-later
version: '{branch}-{build}'

clone_depth: 100

# do not build feature branches with open pull requests
skip_branch_with_pr: true

# avoid building 32-bit if 64-bit failed already
matrix:
  fast_finish: true

environment:
  PACMAN_OPTIONS: "--needed --noconfirm --noprogressbar --overwrite \\*"
  matrix:
    - MSYSTEM: MINGW64
    - MSYSTEM: MINGW32


init:
  - if "%APPVEYOR_PULL_REQUEST_NUMBER%" NEQ ""
      appveyor UpdateBuild -Version "!%APPVEYOR_PULL_REQUEST_NUMBER% (%APPVEYOR_REPO_BRANCH%-%APPVEYOR_BUILD_NUMBER%)"

install:
  - git submodule update --init --recursive

build_script:
  - del C:\Windows\System32\libssl-*.dll C:\Windows\system32\libcrypto-*.dll
  - del C:\Windows\SysWOW64\libssl-*.dll C:\Windows\SysWOW64\libcrypto-*.dll
  - C:\msys64\usr\bin\pacman -Syuu %PACMAN_OPTIONS%
  - C:\msys64\usr\bin\bash --login -c "$(cygpath ${APPVEYOR_BUILD_FOLDER})/buildtools/appveyor.sh"


artifacts:
  - path: build\inkscape*.7z
  - path: build\inkscape*.exe
  - path: build\inkscape*.msi

cache:
  - '%APPVEYOR_BUILD_FOLDER%\build\ccache'

test: off
