This repository has been archived by the owner on Aug 11, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.travis.yml
114 lines (103 loc) · 4.89 KB
/
.travis.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
---
language: python
cache:
directories:
- "$HOME/.cache/pip"
- "$HOME/.pyenv"
matrix:
include:
- os: linux
python: '2.7'
- os: linux
python: '3.6'
env: BUILD_SDIST=true
- os: osx
language: objective-c
env: PYENV_VERSION=2.7.17
- os: osx
language: objective-c
env:
- PYENV_VERSION=3.7.5
- PYTHON_CONFIGURE_OPTS="--enable-framework"
- BUILD_OSX_APP=true
- os: linux
python: 'pypy3'
env:
global:
# This sets the encrypted value for SHINNECOCK_ENDPOINT_TOKEN
- secure: "R7I1Jp8E5jvPAokFfbYlO4Ft4EucaL57m46zc/SUZfRYmhizTNgyY7QQPMpd3xhXcLRHzwnOXRrXRi2PapFOvVsAVXebhjBulPonKxMwli+HVLCaMzzBFL/R5U9We9bw/Y+FTMU7/9AXQriJPUPC2cJyppm/eclT6IV/6a2ZE1W8ELk0Zl/2MxLuwhh4GrUnOCq6rpji+8w7g/jLq7+zODSCpe3C2KIzA5o9RSMAUASzP15L/b5v8mZLUMfPe3nAfUZGkhFLDNLUowVXRu8yDgev49wAplUHwW3xXALJ1EJLtag37mlxL/x8XOwHbT9Z3Xn+ca7n6H2cjUbvzpW59+1oDhhjnMwqxXR3787ZnFlenMWS9Ru8ZdpMgHKJaNFNe2Od41HtVxjMQkTpX+zu5611SKwYd3H1UYPTuDgUP+syQudOqgjHYLy0EVTGhuefldC2gEKYfuvQV6GULTUmoAkIKZYzqtY0TpuxX70sic+uk3dwn9GBH0uOjY5cmPpt59cZH5PId8b9bLqn/qZGPRONUt+dbx21Bdcwe9uOSyVhR7nTQu8b217aN+BTHXZPKhrmuozKc8WnUNctWb4rL76/06R0iqI0QRxoc9dL7ik/GKUrSEg1Q72+kvExTaFMhukHtNk8SOQSGMp26o8xLPOT2RF1x9NQnk+XkD+MDHw="
install:
- echo "Build $TRAVIS_BUILD_NUMBER BRANCH=$TRAVIS_BRANCH TAG=$TRAVIS_TAG"
- |
# Install
if [[ $TRAVIS_OS_NAME == "osx" ]]; then
if [ ! -e "$HOME/.pyenv/.git" ]; then
if [ -e "$HOME/.pyenv" ]; then
rm -rf ~/.pyenv
fi
git clone https://github.com/pyenv/pyenv.git ~/.pyenv --depth 10
else
(cd ~/.pyenv; git pull)
fi
PYENV_ROOT="$HOME/.pyenv"
PATH="$PYENV_ROOT/bin:$PATH"
hash -r
eval "$(pyenv init -)"
hash -r
pyenv install --list
pyenv install -s $PYENV_VERSION
pyenv rehash
pip install wheel
# Since pyenv is apparently cached across builds, uninstall first for a fresh build
if pip show kintyre-speedtest-agent; then pip uninstall -y kintyre-speedtest-agent; fi
fi
- pip install coverage
- pip install codecov
- pip install .
- pip list
script:
- export
SHINNECOCK_UUID=b9f45f86-5a3a-4ce6-8099-8fd3056258be
SHINNECOCK_NAME="travis-${TRAVIS_BUILD_NUMBER}"
SHINNECOCK_ORG="automated-testing"
SHINNECOCK_ENDPOINT_URL=https://splunkspeedtest.kintyre.net
- kintyre-speedtest --version
# Note SHINNECOCK_ENDPOINT_* settings are included (encrypted) above
- kintyre-speedtest --register --no-prompt
- coverage run kintyre_speedtest.py
after_success:
- codecov
- if [[ $BUILD_SDIST == "true" && $TRAVIS_BRANCH =~ ^v.* ]]; then export DO_RELEASE=true; echo "Can we build it? Yes we can!"; else echo "nah"; fi
- |
if [[ $BUILD_OSX_APP == "true" && $TRAVIS_BRANCH =~ ^v.* ]]; then
export BUILD_OSX_APP=now
echo "Launching pyinstaller...."
pip install pyinstaller
pyinstaller kintyre_speedtest.py
(cd dist; zip kintyre_speedtest-macosx-${TRAVIS_BRANCH}.zip -r kintyre_speedtest; )
else
echo "another time, perhaps?"
fi
deploy:
# Push to GitHub releases
- provider: releases
api_key:
secure: BDEpiA11Ua7h/gnncEbFyix6+l3HoPgc8YpXkwRZ69UDuSqgcMIKUIZrJsmU0sgTRG3rn2U2ArmEc10oK4Wx/dnKBNK3NHGMxWJxkJYEt1dXU8sa87vHpllKRp2pFAXSN2uU2CUe3Mi8OOG4xZwrNqSJuSrW5G4jbYl2JztDTdMagDnkUbhHIpx5kQENbzZp3Fgm8P/gEpeLrazqgc1c8QYa7yuYLSL7JgKH2OBiWMGbRbj6ecWjqYs4jqDBF5ezYJK0wJ5tXEMJx6EOkmqgk4OUExRHHKgLu964WFSZLvgee675sVLMhsp/prEiMUh2AfDR9JdynVGWHqLgCb2N0fJRZm/S16tG3v5HGhtMnAcK0rmphfWtQTUp+0RTjum2SPxVLt4ZVF2OTK+Q9vrc7pApf80PrRaZcM6umqCY1188A14nAm/NTugUAzRpcs0cquwcxqisGbaAGyAZtSZwK0BRX4wyl7bQAURJ6nc/HKqmsGbOUh0ezpXuUx8cuRbt/ztWXAskYFZAQPA+TMsuw4hun3lgBmhXDxCo1/xUO2Fsq3MlzaAKkeOsHTjP+NbipZcWcy7BgDYfqj0zREvIn73kY+NlifixHWs3KPkxaafkRCZ1L0yVgCM/amdD0uEIsMZWs5rIHfdGCZ4t228wsN5KHXath4S3MWl/MjxcN08=
file: dist/kintyre*.zip
file_glob: true
skip_cleanup: true
on:
all_branches: true
condition: $BUILD_OSX_APP = "now"
- provider: pypi
user: __token__
password:
secure: "s4mK5a2c6tQIy2mA/JfmVTpuzBNA8OfH+aIlRpfjviwvNimalsuw8aVxJOXg2bH+i7yMFcfybJUuZ9w1zh+xDCAirY5oD87kZ5oJ74vploLbBwe1rkpN61QC/H2wMJh5kg78kmFIi5ONrUfqsWjnDbLnRepCYlAlyfH/fSVqr2QQLgHec2e3XYDgmTfTE6OUMUy/dCBbGMmC6CuPStsp1nzkoKBipuq55YEPuczaL5BAD5E/q87vlwxaJ7ku+lGSduob3cUfNuY8InVspwRtt99so6UflJFbZk3zVbSlcSR8ff/bY417XrbVo8ytSp00EsFkABt7FmOGbM3OKDa0fw50Lv0exjuNb1+BkX7jzMUGro+3JvjmaZblkikomSlAWDe1eaOvPd2s21ZRM960p5ktI+shJmm51RnsJxe+YUGeU0oY8Yg1FA5RhUzewoTJbk0a7YqUspDSMa9aJJvnhNXBArqD1IAM5LRGNrPW4ncPMCR0om81BT/1zHsokt1lM1uEF4ttdmKVeACQaRcyH7Wh7wRWbSQSP59LxHs2Ghsi7g+P5X77T+cfhQPu7CemFccrgBj2ADtYsHf6H+TA5UTb42e8k6TXAGAaB5hNl148TRsjZM7hMxQ+S+OjoQbVi8ZNh2Ubos6LUefKTfQlVEyoXKv5kJPKql2bxFO/GaA="
distributions: "sdist bdist_wheel"
skip_cleanup: true
on:
all_branches: true
condition: $DO_RELEASE = "true"
notifications:
email:
- lowell@kintyre.co