forked from jingkaimori/midieditor
-
-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy path.travis.yml
72 lines (62 loc) · 2.99 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
language: cpp
sudo: required
dist: trusty
branches:
only:
- master
- /^\d+\.\d+\.\d+(\.\d+)?$/
os:
- linux
env:
global:
- CONFIG=Release
- MIDIEDITOR_RELEASE_VERSION_ID=2
- MIDIEDITOR_RELEASE_VERSION_STRING=$TRAVIS_TAG
- MIDIEDITOR_PACKAGE_VERSION=1
- INSTALLJAMMER=installjammer/installjammer
matrix:
- BUILD_OS=LINUX MIDIEDITOR_BINARY=MidiEditor
- BUILD_OS=WINDOWS MXE=/usr/lib/mxe/ PATH=$MXE/usr/bin:$PATH MIDIEDITOR_BINARY_WINDOWS=windows32_build/.build/bin/MidiEditor.exe
before_install:
- if [ "$BUILD_OS" = "LINUX" ]; then sudo add-apt-repository --yes ppa:ubuntu-sdk-team/ppa; fi
- if [ "$BUILD_OS" = "LINUX" ]; then sudo apt-get update -qq; fi
- if [ "$BUILD_OS" = "LINUX" ]; then sudo apt-get install qtbase5-dev qtdeclarative5-dev libqt5webkit5-dev libsqlite3-dev; fi
- if [ "$BUILD_OS" = "LINUX" ]; then sudo apt-get install qt5-default qttools5-dev-tools qtmultimedia5-dev libqt5multimedia5 libqt5multimedia5-plugins; fi
- if [ "$BUILD_OS" = "LINUX" ]; then sudo apt-get install libasound2-dev; fi
- if [ "$BUILD_OS" = "LINUX" ]; then sudo apt-get install fakeroot; fi
- QT_VERSION_MM=59
- QT_VERSION_FULL=591-trusty
# For mxe.cc (see http://mxe.cc/#requirements)
- if [ "$BUILD_OS" = "WINDOWS" ]; then echo 'deb http://pkg.mxe.cc/repos/apt/debian wheezy main' | sudo tee -a /etc/apt/sources.list.d/mxeapt.list; fi
- if [ "$BUILD_OS" = "WINDOWS" ]; then sudo apt-key adv --keyserver keyserver.ubuntu.com --recv-keys D43A795B73B16ABE9643FE1AFD8FFF16DB45C6AB; fi
- if [ "$BUILD_OS" = "WINDOWS" ]; then sudo apt-get update; fi
- if [ "$BUILD_OS" = "WINDOWS" ]; then sudo apt-get install mxe-i686-w64-mingw32.static-qtbase mxe-i686-w64-mingw32.static-qtmultimedia; fi
before_script:
script:
- if [ "$BUILD_OS" = "WINDOWS" ]; then sh building/build-windows.sh; fi
- if [ "$BUILD_OS" = "LINUX" ]; then sh building/build-linux.sh; fi
before_deploy:
- if [ "$BUILD_OS" = "WINDOWS" ]; then git clone https://github.com/damoncourtney/installjammer.git installjammer; fi
- if [ "$BUILD_OS" = "WINDOWS" ]; then cd installjammer; fi
- if [ "$BUILD_OS" = "WINDOWS" ]; then git tag -l; fi
- if [ "$BUILD_OS" = "WINDOWS" ]; then git checkout tags/v1.2.14; fi
- if [ "$BUILD_OS" = "WINDOWS" ]; then cd ../; fi
- if [ "$BUILD_OS" = "WINDOWS" ]; then sh packaging/windows/create_windows_setup.sh; fi
- if [ "$BUILD_OS" = "WINDOWS" ]; then DEPLOY_BINARIY=releases/MidiEditor-$MIDIEDITOR_RELEASE_VERSION_STRING-Setup.exe; fi
- if [ "$BUILD_OS" = "LINUX" ]; then sh packaging/unix/build_deb.sh; fi
- if [ "$BUILD_OS" = "LINUX" ]; then DEPLOY_BINARIY=releases/midieditor_$MIDIEDITOR_RELEASE_VERSION_STRING-$MIDIEDITOR_PACKAGE_VERSION-amd64.deb; fi
deploy:
provider: releases
prerelease: true
skip-cleanup: true
api_key: $GITHUB_TOKEN
keep-history: true
on:
tags: true
file: $DEPLOY_BINARIY
notifications:
email:
recipients:
on_success: always
on_failure: always