.travis.yml 1.7 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677
  1. os: linux
  2. dist: bionic
  3. language: python
  4. cache:
  5. - directories:
  6. - $HOME/.cache/pip
  7. addons:
  8. firefox: "latest"
  9. install:
  10. - env
  11. - which python; python --version
  12. - make V=1 install
  13. - make V=1 gecko.driver
  14. - make V=1 node.env
  15. - make V=1 travis.codecov
  16. script:
  17. - make V=1 themes
  18. - make V=1 test
  19. after_success:
  20. - make V=1 test.coverage
  21. - codecov
  22. stages:
  23. - test
  24. - name: documentation
  25. if: env(GITHUB_TOKEN) IS present
  26. - name: docker
  27. if: branch = master AND type != pull_request AND env(DOCKER_USERNAME) IS present
  28. jobs:
  29. include:
  30. - python: "3.5"
  31. - python: "3.6"
  32. - python: "3.7"
  33. - python: "3.8"
  34. - stage: documentation
  35. python: "3.8"
  36. addons: []
  37. before_install:
  38. - sudo ./utils/searx.sh install buildhost
  39. install: true
  40. script:
  41. - SEARX_DEBUG=1 make travis-gh-pages
  42. after_success: true
  43. deploy:
  44. provider: pages
  45. edge: false
  46. token: $GITHUB_TOKEN # Set in the settings page of your repository, as a secure variable
  47. strategy: git
  48. skip_cleanup: true
  49. keep_history: true
  50. local_dir: gh-pages
  51. target_branch: gh-pages
  52. on:
  53. branch: master
  54. - stage: docker
  55. python: "3.8"
  56. git:
  57. depth: false
  58. services:
  59. - docker
  60. addons: []
  61. before_install: true
  62. install: true
  63. script:
  64. - echo "$DOCKER_PASSWORD" | docker login -u "$DOCKER_USERNAME" --password-stdin
  65. - make -e GIT_URL=$(git remote get-url origin) docker.push
  66. after_success: true
  67. notifications:
  68. irc:
  69. channels:
  70. - "irc.freenode.org#searx"
  71. template:
  72. - "%{repository}/#%{build_number}/%{branch} (%{author}): %{message} %{build_url}"
  73. on_success: change