UNPKG

@gmod/jbrowse

Version:

JBrowse - client-side genome browser

124 lines (123 loc) 4.71 kB
sudo: true dist: trusty language: perl python: 2.7.10 perl: - '5.26' - '5.14' addons: apt: packages: - libdb-dev - libgd2-noxpm-dev firefox: '58.0' cache: yarn: true directories: - extlib/ - node_modules/ - "$HOME/perl5/" - "$HOME/python/" - "$HOME/.nvm/" env: global: - GECKODRIVER_VERSION=0.19.1 before_install: - sudo dpkg --add-architecture i386 - sudo apt-get install wine1.6 # this is for building windows electron images install: - mkdir ~/geckodriver_$GECKODRIVER_VERSION; - wget -O - https://github.com/mozilla/geckodriver/releases/download/v0.19.1/geckodriver-v$GECKODRIVER_VERSION-linux64.tar.gz | tar -xzf - -C ~/geckodriver_$GECKODRIVER_VERSION; - export PATH=$PATH:$HOME/geckodriver_$GECKODRIVER_VERSION - cpanm --notest GD::Image Text::Markdown DateTime JSON # only init the python virtualenv if it did not show up in our build cache - if [[ ! -f ~/python/bin/activate ]]; then virtualenv ~/python; fi - source ~/python/bin/activate - pip install nose selenium script: # these versions *should* already be set in version control, but set them again here just in case - if [[ "x$TRAVIS_PULL_REQUEST_BRANCH" != "x" && $TRAVIS_BRANCH == "master" ]]; then return 1; fi - if [[ "x$TRAVIS_TAG" != "x" ]]; then build/set_package_versions.pl $TRAVIS_TAG src/JBrowse/package.json package.json website/siteConfig.js; fi - RELEASE_VERSION=`node -e 'require("fs").readFile("src/JBrowse/package.json", (e,d)=>console.log(JSON.parse(d).version))'` - BUILD_DIR=$PWD - set -e - JBROWSE_BUILD_MIN=0 ./setup.sh - yarn lint - prove -Isrc/perl5 -r -j3 tests/perl_tests; - utils/jb_run.js -p 9000 & sleep 2 - node tests/js_tests/run-puppeteer.js http://localhost:9000/tests/js_tests/index.html - utils/jb_run.js -p 8000 -s jbrowse & sleep 2 - node tests/js_tests/run-puppeteer.js http://localhost:8000/jbrowse/tests/js_tests/index.html - xvfb-run node_modules/.bin/ava --timeout=60s tests/electron_tests - MOZ_HEADLESS=1 SELENIUM_BROWSER=firefox JBROWSE_URL=http://localhost:9000/index.html tests/selenium_tests/travis_wrapper.sh; # if we are building for inclusion into the `dev` branch, build the releases and test the minimal one too - | if [[ "x$TRAVIS_TAG" != "x" || $TRAVIS_BRANCH = "master" || $TRAVIS_BRANCH = "dev" || $TRAVIS_PULL_REQUEST != "false" ]]; then make -f build/Makefile; rm -rf JBrowse-*/; unzip -q JBrowse-$RELEASE_VERSION.zip; cd JBrowse-$RELEASE_VERSION/; cp -r ../tests/ .; ./setup.sh; prove -Isrc/perl5 -r -j3 tests/perl_tests; cd $BUILD_DIR; MOZ_HEADLESS=1 SELENIUM_BROWSER=firefox NOSEOPTS="-I jasmine" JBROWSE_URL=http://localhost:9000/JBrowse-$RELEASE_VERSION/index.html tests/selenium_tests/travis_wrapper.sh; # remove symlink and copy actual files to dir for upload to s3 rm JBrowse-$RELEASE_VERSION/sample_data/raw/volvox cp -R docs/tutorial/data_files JBrowse-$RELEASE_VERSION/sample_data/raw/volvox fi - set +e - website/build.sh after_failure: - cat setup.log before_cache: - rm -f node_modules/.cache deploy: # upload both minified and non-minified builds to GitHub releases - provider: releases api_key: secure: BuOD7rqrcGKT3g0hVY5AGpJI/Kkko4DhSIYSUQ28sS2AOdoNyTD0t5doL/Kiq4BC41q198tbFFt1dnXGdo8YKpBSXO/uGUuuiGtMFHM++I84oLq20p49iyrenNZ4m/jy/Q4YtizIYLs83DVzVdQzhJ5hrTx6f+d1gc9EgaMeBF4= file: JBrowse-1.*.zip file_glob: true skip_cleanup: true on: repo: GMOD/jbrowse perl: 5.26 tags: true # upload regular non-minified version to npm - provider: npm email: rbuels@gmail.com skip_cleanup: true api_key: secure: "OpxHZGvyCFeG2CUpw4dHTz3kFBHJXeET2c4XxwKMxtL2FVt4W/zDLUV0gLQDFfsLlj+zjF62qtbHU8MajMw3aFLlTIdMIit+2s6H4D8kuBh5Q7pO5/gAykWtiwkJ3BudoYDGoDlB5kkakG4MPvvY26490hbmySCSgpsjetM91zE=" on: repo: GMOD/jbrowse perl: 5.26 tags: true # upload built jbrowse to s3 bucket for demo on main site - provider: s3 access_key_id: $AWS_ACCESS_KEY secret_access_key: $AWS_SECRET_KEY bucket: "jbrowse.org" skip_cleanup: true local-dir: JBrowse-$RELEASE_VERSION upload-dir: code/JBrowse-$RELEASE_VERSION cache_control: "max-age=1800" on: tags: true repo: GMOD/jbrowse perl: 5.26 condition: $TRAVIS_COMMIT_MESSAGE =~ (\[update docs\]) # add this extra condition so that it basically corresponds with the real build published and not a test tag # upload the docusaurus website to the s3 bucket also - provider: s3 access_key_id: $AWS_ACCESS_KEY secret_access_key: $AWS_SECRET_KEY bucket: "jbrowse.org" skip_cleanup: true local-dir: website/build/jbrowse/ cache_control: "max-age=1800" on: perl: 5.26 repo: GMOD/jbrowse condition: $TRAVIS_COMMIT_MESSAGE =~ (\[update docs\]) all_branches: true