os: linux dist: bionic language: python services: - mongodb before_install: - sudo apt-get install -y xmlsec1 install: - pip install tox - pip install tox-travis script: - tox jobs: allow_failures: - python: 3.10-dev - python: pypy3 include: - python: 3.6 - python: 3.7 - python: 3.8 - python: 3.9 - python: 3.10-dev - python: pypy3 - stage: Expose env-var information script: | cat <VERSION deploy: - provider: pypi distributions: sdist bdist_wheel server: "https://test.pypi.org/legacy/" skip_cleanup: true username: "__token__" password: "$PYPI_PRE_RELEASE_TOKEN" on: repo: IdentityPython/pysaml2 - stage: Deploy new release on PyPI if: type = push AND tag IS present before_install: skip install: skip script: skip deploy: - provider: pypi distributions: sdist bdist_wheel username: "__token__" password: "$PYPI_RELEASE_TOKEN" on: repo: IdentityPython/pysaml2 tags: true - stage: Deploy new release on GitHub if: type = push AND tag IS present before_install: skip install: skip script: skip deploy: - provider: releases token: "$GITHUB_RELEASE_TOKEN" on: repo: IdentityPython/pysaml2 tags: true