matrix:
  include:
    - name: Discord
      language: python
      python: 3.7
      # Workaround for Python 3.7
      # https://github.com/travis-ci/travis-ci/issues/9815
      dist: xenial
      sudo: true
      cache:
        pip: true
        directories:
          - $HOME/.imageio
      script:
        - cd Discord
        - python Harmonbot.py
    - name: Telegram
      language: python
      python: 3.7
      # Workaround for Python 3.7
      # https://github.com/travis-ci/travis-ci/issues/9815
      dist: xenial
      sudo: true
      cache:
        pip: true
      script:
        - cd Telegram
        - python Telegram_Harmonbot.py
    - name: Discord Listener
      language: go
      go: 1.6
      install:
        - go get github.com/bwmarrin/discordgo
        - go get github.com/bwmarrin/dgvoice
      script:
        - cd Discord
        - go run Harmonbot_Listener.go

matrix:
  include:
    - name: Discord
      language: python
      python: 3.7
      # Workaround for Python 3.7
      # https://github.com/travis-ci/travis-ci/issues/9815
      dist: xenial
      sudo: true
      cache:
        pip: true
        directories:
          - $HOME/.imageio
      before_script:
        - cd Discord
      script:
        - python Harmonbot.py
    - name: Telegram
      language: python
      python: 3.7
      # Workaround for Python 3.7
      # https://github.com/travis-ci/travis-ci/issues/9815
      dist: xenial
      sudo: true
      cache:
        pip: true
      before_script:
        - cd Telegram
      script:
        - python Telegram_Harmonbot.py
    - name: Discord Listener
      language: go
      go: 1.6
      install:
        - go get github.com/bwmarrin/discordgo
        - go get github.com/bwmarrin/dgvoice
      before_script:
        - cd Discord
      script:
        - go run Harmonbot_Listener.go

Use before script step in Travis CI configuration to change directories
Use before script step in Travis CI configuration to change directories

