language: ruby
rvm:
  - 2.5.1

cache:
  bundler: true
  directories:
    - node_modules
    - $TRAVIS_BUILD_DIR/tmp/.htmlproofer # https://github.com/gjtorikian/html-proofer/issues/381

env:
  global:
    - NOKOGIRI_USE_SYSTEM_LIBRARIES=true

addons:
  ssh_known_hosts: 
    - kjaermaxi.me
    - kjaer.io
  apt:
    packages:
      - graphviz              # to compile graphs to svg
      - libcurl4-openssl-dev  # to avoid SSL errors


before_install:
  - bash _scripts/install.sh

jobs:
  include:
    - stage: build
      name: Jekyll build
      script: bash _scripts/build.sh
    - stage: test
      name: Test HTML
      script: npm run test
    - stage: test
      name: Optimize
      language: node_js
      node_js: "lts/*"
      script: bash _scripts/optimize.sh
    - stage: deploy
      name: Deploy
      language: minimal
      if: branch = master
      script: bash _scripts/deploy.sh

language: ruby
rvm:
  - 2.5.1

cache:
  bundler: true
  directories:
    - node_modules
    - $TRAVIS_BUILD_DIR/tmp/.htmlproofer # https://github.com/gjtorikian/html-proofer/issues/381

env:
  global:
    - NOKOGIRI_USE_SYSTEM_LIBRARIES=true

addons:
  ssh_known_hosts: 
    - kjaermaxi.me
    - kjaer.io
  apt:
    packages:
      - graphviz              # to compile graphs to svg
      - libcurl4-openssl-dev  # to avoid SSL errors


before_install:
  - bash _scripts/install.sh

jobs:
  include:
    - stage: build
      name: Jekyll build
      script: bash _scripts/build.sh
    - stage: test
      name: Test HTML
      script: travis_wait 25 npm run test
    - stage: test
      name: Optimize
      language: node_js
      node_js: "lts/*"
      script: bash _scripts/optimize.sh
    - stage: deploy
      name: Deploy
      language: minimal
      if: branch = master
      script: bash _scripts/deploy.sh

Change test stage timeout to 25 minutes
Change test stage timeout to 25 minutes

