diff options
author | Rémi Nicole <nicole@kolabsystems.com> | 2018-02-27 18:02:52 +0100 |
---|---|---|
committer | Christian Mollekopf <chrigi_1@fastmail.fm> | 2018-02-27 18:03:04 +0100 |
commit | 117654d14339f22b2cf8abab92575aeef0f4e558 (patch) | |
tree | f3ab12ad36cb887270e424305e0dc3f91892f008 /.travis | |
parent | 8a8729a371373d5c841e058ab21f4fdd0169b40a (diff) | |
download | kube-117654d14339f22b2cf8abab92575aeef0f4e558.tar.gz kube-117654d14339f22b2cf8abab92575aeef0f4e558.zip |
Add Travis-CI integration
Summary:
Some notes:
- From what I've seen, the `.travis.yml` file (and by extension the `.travis` dir) needs to be on every branch we want Travis to build continuously + the main (master) branch for detection
- Since every branch continuously tested must have the `.travis.yml` file, that allows for feature specific dependency version pinning
- The Sink dependency follows the "develop" branch, but Travis will not detect new commits in Sink, so to update, either trigger a build manually on Travis-CI, or make a new commit in Kube
- Unit Tests are disabled for now
Reviewers: cmollekopf
Tags: #kube
Differential Revision: https://phabricator.kde.org/D10891
Diffstat (limited to '.travis')
-rwxr-xr-x | .travis/install-flatbuffers.sh | 14 | ||||
-rwxr-xr-x | .travis/install-gpg.sh | 20 | ||||
-rwxr-xr-x | .travis/install-kde.sh | 15 |
3 files changed, 49 insertions, 0 deletions
diff --git a/.travis/install-flatbuffers.sh b/.travis/install-flatbuffers.sh new file mode 100755 index 00000000..9a030084 --- /dev/null +++ b/.travis/install-flatbuffers.sh | |||
@@ -0,0 +1,14 @@ | |||
1 | #!/bin/bash | ||
2 | set -xeuo pipefail | ||
3 | wget "https://github.com/google/flatbuffers/archive/v1.8.0.tar.gz" -O /tmp/flatbuffers.tar.gz | ||
4 | cd /tmp | ||
5 | tar xvfa /tmp/flatbuffers.tar.gz | ||
6 | cd flatbuffers-1.8.0 | ||
7 | mkdir build | ||
8 | cd build | ||
9 | cmake .. -G Ninja -DCMAKE_INSTALL_PREFIX=/usr -DFLATBUFFERS_BUILD_SHAREDLIB=ON | ||
10 | ninja | ||
11 | sudo ninja install | ||
12 | sudo cp flatc /usr/bin | ||
13 | cd | ||
14 | rm -rf /tmp/flatbuffers.tar.gz /tmp/flatbuffers-1.8.0 | ||
diff --git a/.travis/install-gpg.sh b/.travis/install-gpg.sh new file mode 100755 index 00000000..9cd6f3e4 --- /dev/null +++ b/.travis/install-gpg.sh | |||
@@ -0,0 +1,20 @@ | |||
1 | #!/bin/bash | ||
2 | set -xeuo pipefail | ||
3 | |||
4 | package=$1 | ||
5 | version=$2 | ||
6 | shift | ||
7 | shift | ||
8 | configure_opts=( "$@" ) | ||
9 | |||
10 | wget "https://www.gnupg.org/ftp/gcrypt/$package/$package-$version.tar.bz2" -O "/tmp/$package.tar.bz2" | ||
11 | cd /tmp | ||
12 | tar xvfa "/tmp/$package.tar.bz2" | ||
13 | cd "$package-$version" | ||
14 | # Expand configure_opts only if configure_opts is not undefined | ||
15 | # (in older versions of Bash, empty array is considered undefined) | ||
16 | ./configure "${configure_opts[@]+"${configure_opts[@]}"}" | ||
17 | make | ||
18 | sudo make install | ||
19 | cd | ||
20 | rm -rf "/tmp/$package.tar.bz2" "/tmp/$package-$version" | ||
diff --git a/.travis/install-kde.sh b/.travis/install-kde.sh new file mode 100755 index 00000000..55cc0f83 --- /dev/null +++ b/.travis/install-kde.sh | |||
@@ -0,0 +1,15 @@ | |||
1 | #!/bin/bash | ||
2 | set -xeuo pipefail | ||
3 | IFS=$'\n\t' | ||
4 | |||
5 | package=$1 | ||
6 | version=$2 | ||
7 | |||
8 | git clone --branch="$version" --depth=1 --recursive "https://anongit.kde.org/$package" "/tmp/$package" | ||
9 | cd "/tmp/$package" | ||
10 | mkdir build | ||
11 | cd build | ||
12 | cmake .. -G Ninja -DCMAKE_INSTALL_PREFIX=/usr | ||
13 | ninja && sudo ninja install | ||
14 | cd | ||
15 | rm -rf "/tmp/$package" | ||