Skip to content
Snippets Groups Projects
.travis.yml 1.45 KiB
Newer Older
  • Learn to ignore specific revisions
  • dist: xenial
    
    Scott Lahteine's avatar
    Scott Lahteine committed
    sudo: require
    
    language: python
    python:
      - "2.7"
    
    
    notifications:
      email: false
    
    
    # Cache PlatformIO packages using Travis CI container-based infrastructure
    sudo: false
    
    Scott Lahteine's avatar
    Scott Lahteine committed
    cache:
    
      pip: true
      directories:
      - "~/.platformio"
    
    env:
    
      - TEST_PLATFORM="megaatmega2560"
      - TEST_PLATFORM="DUE"
    
    Scott Lahteine's avatar
    Scott Lahteine committed
      - TEST_PLATFORM="LPC1768"
    
      - TEST_PLATFORM="LPC1769"
    
      - TEST_PLATFORM="STM32F1"
    
      - TEST_PLATFORM="teensy35"
    
    Scott Lahteine's avatar
    Scott Lahteine committed
      - TEST_PLATFORM="linux_native"
    
      - TEST_PLATFORM="esp32"
    
    Scott Lahteine's avatar
    Scott Lahteine committed
    
    addons:
      apt:
        sources:
          - ubuntu-toolchain-r-test
        packages:
          - g++-7
    
    Scott Lahteine's avatar
    Scott Lahteine committed
      - sudo update-alternatives --install /usr/bin/g++ g++ /usr/bin/g++-7 90
    
      # Fetch the tag information for the current branch
    
    João Brázio's avatar
    João Brázio committed
      #
      # Publish the buildroot script folder
      - chmod +x ${TRAVIS_BUILD_DIR}/buildroot/bin/*
    
      - chmod +x ${TRAVIS_BUILD_DIR}/buildroot/share/tests/*
    
      - export PATH=${TRAVIS_BUILD_DIR}/buildroot/bin/:${TRAVIS_BUILD_DIR}/buildroot/share/tests/:${PATH}
    
    install:
    
      #- pip install -U platformio
    
      - pip install -U https://github.com/platformio/platformio-core/archive/master.zip
    
      # Update PlatformIO packages
      - platformio update
    
    João Brázio's avatar
    João Brázio committed
      #
      # Change current working directory to the build dir
      - cd ${TRAVIS_BUILD_DIR}
    
      # Generate custom version include
    
      - generate_version ${TRAVIS_BUILD_DIR}/Marlin/src/inc
    
    Scott Lahteine's avatar
    Scott Lahteine committed
      - cat ${TRAVIS_BUILD_DIR}/Marlin/src/inc/_Version.h
    
    Scott Lahteine's avatar
    Scott Lahteine committed
      - run_tests ${TRAVIS_BUILD_DIR} ${TEST_PLATFORM}