---
version: "{build}"
branches:
  only:
    - master
clone_depth: 10
install:
  - SET PATH=C:\Ruby%ruby_version%\bin;%PATH%
  # https causes certificate verification errors
  # Updating rubygems resolves this, but then gem install seems to hang for unknown reasons
  # Use http instead as a workaround
  # - gem update --system
  - gem sources -r https://rubygems.org/
  - gem install bundler --no-ri --no-rdoc --source http://rubygems.org/
  - bundle install
  - cinst graphviz.portable
  - cinst imagemagick
  - cinst phantomjs
  - npm install -g mermaid
  - npm install -g wavedrom-cli
build_script:
  - bundle exec rake package
test_script:
  - bundle exec rake test
artifacts:
  - path: pkg\*.gem

environment:
  matrix:
    - ruby_version: "193"
    - ruby_version: "200"
    - ruby_version: "200-x64"
    - ruby_version: "21"
    - ruby_version: "21-x64"

---
version: "{build}"
branches:
  only:
    - master
clone_depth: 10
install:
  - SET PATH=C:\Ruby%ruby_version%\bin;%PATH%
  # https causes certificate verification errors
  # Updating rubygems resolves this, but then gem install seems to hang for unknown reasons
  # Use http instead as a workaround
  # - gem update --system
  - gem sources -r https://rubygems.org/
  - gem install bundler --no-ri --no-rdoc --source http://rubygems.org/
  - bundle install
#  - cinst graphviz.portable
  - ps: (new-object net.webclient).DownloadFile('https://github.com/ErwinJanssen/graphviz/releases/download/v2.38/graphviz-2.38.msi', 'graphviz.msi')
  - ps: msiexec /i graphviz.msi /quiet /qn /norestart
  - cinst imagemagick
  - cinst phantomjs
  - npm install -g mermaid
  - npm install -g wavedrom-cli
build_script:
  - bundle exec rake package
test_script:
  - bundle exec rake test
artifacts:
  - path: pkg\*.gem

environment:
  matrix:
    - ruby_version: "193"
    - ruby_version: "200"
    - ruby_version: "200-x64"
    - ruby_version: "21"
    - ruby_version: "21-x64"

Install graphviz on Appveyor from github. graphviz.org is not reliable enough.
Install graphviz on Appveyor from github. graphviz.org is not reliable enough.
