/ .travis.yml
.travis.yml
 1  # This is a common .travis.yml for generating library release zip files for
 2  # CircuitPython library releases using circuitpython-build-tools.
 3  # See https://github.com/adafruit/circuitpython-build-tools for detailed setup
 4  # instructions.
 5  
 6  dist: xenial
 7  language: python
 8  python:
 9    - "3.6"
10  
11  cache:
12    pip: true
13  
14  # TODO: if deployment to PyPi is desired, change 'DEPLOY_PYPI' to "true",
15  #       or remove the env block entirely and remove the condition in the
16  #       deploy block.
17  env:
18    - DEPLOY_PYPI="true"
19  
20  deploy:
21    - provider: releases
22      api_key: "$GITHUB_TOKEN"
23      file_glob: true
24      file: "$TRAVIS_BUILD_DIR/bundles/*"
25      skip_cleanup: true
26      overwrite: true
27      on:
28        tags: true
29    # TODO: Use 'travis encrypt --com -r adafruit/<repo slug>' to generate
30    #       the encrypted password for adafruit-travis. Paste result below.
31    - provider: pypi
32      user: adafruit-travis
33      password:
34        secure: ZxsMZrdftjJBqxdW4fowdLWFR5ykdCawV6pQt1BwRO8Q+6PGRloGkpIBQ2tj9eX85YY8q5sBIhqNwODJ5od9/B7nbx3xTo8T79O5Nq//tv9zmZaQS/uqZo8fj9TaHpaq+MVH2aCRfepey9/OzVRRsIZW/nEpaHuDPow7UtaoGFij4VsZ66RoVm88J7Zer8/bVlOdYatmMpb8SOSRE8Hj6jx7F4ayVxF2hVdzd8wOxrKObDkEFZ9ym0xYKHMWdPehtbnCOo/rgm0jtutd8plrKnTm//qNFEp6CdRcLbCEL6cQoPOWzk47p7tGe42yHllquB//f2VqmGzep3+YverAAOrPG2XOxp2ypQFc0RL6KY6CpDqWAdfYh+/H5o74oxCvRVWyUyHZ2eTHrd6YKnwlhxDTk0+A7FwforEPODm/YGxoTrRXduiD+LR4xvPFaQISAyFjIOeCYA1Yyfz4ZTQgcpXwqAa4irLlfb3rdjWRZIRnhR6mQsd1nTqDaxXcqlbL/EIH8KKG0ZBIAXL7F73ajRblaVn2iHvYkrTDKQhR8yaIFBUgAoSXdCBY1TIg3/RWU/knRyQItEKiQHXgua+gVO95GT4a2Hf2yV4y3PoaXCSoAVF24hgnHN9WRIEpyVRHgcMJpH2bLnXmDnl8KPgEqZD586tQaCqZdIdKtNJhUbo=
35      on:
36        tags: true
37        condition: $DEPLOY_PYPI = "true"
38  
39  install:
40    - pip install -r requirements.txt
41    - pip install circuitpython-build-tools Sphinx sphinx-rtd-theme
42    - pip install --force-reinstall pylint==1.9.2
43  
44  script:
45    - pylint adafruit_button.py
46    - ([[ ! -d "examples" ]] || pylint --disable=missing-docstring,invalid-name,bad-whitespace examples/*.py)
47    - circuitpython-build-bundles --filename_prefix adafruit-circuitpython-display_button --library_location .
48    - cd docs && sphinx-build -E -W -b html . _build/html && cd ..