sudo: required services: - docker language: cpp dist: bionic script: - docker build --tag onnx-mlir-build:initial ./docker - docker run -itd --name build onnx-mlir-build:initial - docker cp $(pwd) build:/build/onnx-mlir - cd docker - chmod a+x compile-onnx-mlir.sh - docker cp compile-onnx-mlir.sh build:/usr/bin/compile-onnx-mlir.sh - docker exec -it build compile-onnx-mlir.sh - docker commit build onnxmlirczar/onnx-mlir-build:latest after_success: - if [ $TRAVIS_PULL_REQUEST == false ] && [ $TRAVIS_BRANCH == "master" ]; then echo "Pushing new build to docker hub"; docker login -u onnxmlirczar -p 143f1da2-332f-45a1-8587-d6cb07c13230; docker push onnxmlirczar/onnx-mlir-build:latest; else echo "Skip pushing build"; fi