<commit_before>---
# yamllint disable rule:line-length
sudo: required
dist: trusty
services:
  - docker
language: node_js
node_js:
  - '6'
cache:
  directories:
    - node_modules
before_install:
  - |
        git config --global user.email "<EMAIL>"
        git config --global user.name "<NAME>"
        git remote add welder https://github.com/weldr/welder-web.git
        git fetch welder
        git log -1 --pretty=format:%H welder/master
        git rebase welder/master

        npm install -g codecov
        npm install -g nyc@11.1.0

        if [ "$COMMAND" == "bdcs-test" ]; then
            sudo docker pull welder/web-e2e-tests:latest
            sudo docker pull welder/web-bdcs:latest
        fi
        if [ "$COMMAND" == "lorax-test" ]; then
            sudo docker pull welder/web-lorax:latest
            sudo docker pull welder/web-e2e-tests:latest
        fi
install:
  - |
        if [ "$COMMAND" != "bdcs-test" ]; then
            npm install
        fi

        if [ "$COMMAND" == "lorax-test" ]; then
            npm rebuild
            node run build --with-coverage
        fi
env:
  global:
    - CXX=g++-4.8
    - secure: Q9X11ehcl4YE0ylxDGk8NgVeO7nIpqWiI9am2GA6JVXcxeYYcLf3NHGe1JiLwFQ/xSq4KJrY0IgpivkVrPwTOojpR/tRG5QNDR/IJzN/6PV0IAWkHjPDKZexCQmy4IoPFib/cWqxo46V/JZ+gzs/TJugkl5/QpTcGlCr+d7VkuA80Bj0nlQO5GevYVgYMCrN6u6cKNOWtNQ0gppxHrpsLo36MpHqHbNbv236GPGsV4K2qpiqvvO5ogD+LCv5xoKEZK0ext4FNrrZFq6XEYdy9uUaUbSFfoG+HXESXbIt0L7krQDT/PkKI0X4nM91eYl5mS63+HVue7vLiijS5h9+YCa8HblMIiAiyrR3lPPH0Hx4FVSrQfkvtoXMBs3nRt7keu2FG370a7WoaQ71Q2jHrI9cfYzRwa/Mok73eF/oeN32hPlPDD679hWOZYqbSksSTikCLIgwJpEgIfaHgEYXFmL2JFXk0HbgIciA+C9fE0rfaUbmARtWYq8c+b52aIxAHEV9zYy3JeARrYxk7s3jQgS/LZIw4rfso+bQIvEMUDWt8MnvKaecY1E7XjOpW1kuk8gVjZbHm6oHKl2IndZA9KNpXjT2ew8d3SB69l2lswUYu4mTdywNEUt6nIaQtROiiftUKYThAbibIEIrq7GxQSOYMUPbvUYsZO5rkVssJps=
    - secure: <KEY>
    - secure: <KEY>
    - secure: <KEY>
  matrix:
    - COMMAND=eslint
    - COMMAND=stylelint
    - COMMAND=unit-test
    - COMMAND=lorax-test
    - COMMAND=bdcs-test
script:
  - make "$COMMAND"
after_success:
  - if [ "$COMMAND" == "unit-test" ]; then cat ./coverage/lcov.info | codecov; fi
  - |
        if [ "$COMMAND" == "lorax-test" ]; then
            nyc report
            nyc report --reporter=lcov && codecov
        fi
        if [ "$TRAVIS_BRANCH" == "master" ] && [ "$TRAVIS_PULL_REQUEST" == "false" ]; then
            docker login -u atodorov -p $DOCKER_PASSWORD
            if [ "$COMMAND" == "lorax-test" ]; then
                # tag the current builds with the build number
                # if nothing has been changed the push will detect that
                # and the new tag will appear on Docker Hub without anything being
                # actually uploaded
                sudo docker tag welder/web-lorax:latest welder/web-lorax:$TRAVIS_BUILD_NUMBER
                sudo docker tag welder/web-e2e-tests:latest welder/web-e2e-tests:$TRAVIS_BUILD_NUMBER
                docker push welder/web-lorax
                docker push welder/web-e2e-tests
            fi
            if [ "$COMMAND" == "bdcs-test" ]; then
                sudo docker tag welder/web-bdcs:latest welder/web-bdcs:$TRAVIS_BUILD_NUMBER
                docker push welder/web-bdcs
            fi<commit_msg>Run `make po-push` from travis on pushes to master.<commit_after>---
# yamllint disable rule:line-length
sudo: required
dist: trusty
services:
  - docker
language: node_js
node_js:
  - '6'
cache:
  directories:
    - node_modules
before_install:
  - |
        git config --global user.email "<EMAIL>"
        git config --global user.name "<NAME>"
        git remote add welder https://github.com/weldr/welder-web.git
        git fetch welder
        git log -1 --pretty=format:%H welder/master
        git rebase welder/master

        npm install -g codecov
        npm install -g nyc@11.1.0

        if [ "$COMMAND" == "bdcs-test" ]; then
            sudo docker pull welder/web-e2e-tests:latest
            sudo docker pull welder/web-bdcs:latest
        fi
        if [ "$COMMAND" == "lorax-test" ]; then
            sudo docker pull welder/web-lorax:latest
            sudo docker pull welder/web-e2e-tests:latest
        fi
install:
  - |
        if [ "$COMMAND" != "bdcs-test" ]; then
            npm install
        fi

        if [ "$COMMAND" == "lorax-test" ]; then
            npm rebuild
            node run build --with-coverage
        fi
env:
  global:
    - CXX=g++-4.8
    - secure: <KEY>
    - secure: <KEY>
    - secure: <KEY>
    - secure: <KEY>
    - secure: <KEY>
    - ZANATA_USER=dshea
  matrix:
    - COMMAND=eslint
    - COMMAND=stylelint
    - COMMAND=unit-test
    - COMMAND=lorax-test
    - COMMAND=bdcs-test
script:
  - make "$COMMAND"
jobs:
  include:
    - stage: deploy
      script: make po-push
      env: COMMAND=none
      if: branch = master AND type = push
after_success:
  - if [ "$COMMAND" == "unit-test" ]; then cat ./coverage/lcov.info | codecov; fi
  - |
        if [ "$COMMAND" == "lorax-test" ]; then
            nyc report
            nyc report --reporter=lcov && codecov
        fi
        if [ "$TRAVIS_BRANCH" == "master" ] && [ "$TRAVIS_PULL_REQUEST" == "false" ]; then
            docker login -u atodorov -p $DOCKER_PASSWORD
            if [ "$COMMAND" == "lorax-test" ]; then
                # tag the current builds with the build number
                # if nothing has been changed the push will detect that
                # and the new tag will appear on Docker Hub without anything being
                # actually uploaded
                sudo docker tag welder/web-lorax:latest welder/web-lorax:$TRAVIS_BUILD_NUMBER
                sudo docker tag welder/web-e2e-tests:latest welder/web-e2e-tests:$TRAVIS_BUILD_NUMBER
                docker push welder/web-lorax
                docker push welder/web-e2e-tests
            fi
            if [ "$COMMAND" == "bdcs-test" ]; then
                sudo docker tag welder/web-bdcs:latest welder/web-bdcs:$TRAVIS_BUILD_NUMBER
                docker push welder/web-bdcs
            fi
{'fraction_non_alphanumeric': 0.10028085246984966, 'fraction_numerical': 0.021807368247150172, 'mean_word_length': 2.153125, 'pattern_counts': {'":': 0, '<': 15, '<?xml version=': 0, '>': 15, 'https://': 2, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 2, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1004439', 'n_tokens_mistral': 2328, 'n_tokens_neox': 2184, 'n_words': 455}