forked from luafun/luafun
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.travis.yml
74 lines (65 loc) · 1.7 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
sudo: false
language: C
services:
- docker
env:
global:
- PRODUCT=lua-fun
matrix:
- OS=el DIST=7
- OS=fedora DIST=24
- OS=fedora DIST=25
- OS=ubuntu DIST=xenial
- OS=ubuntu DIST=yakkety
- OS=debian DIST=stretch
before_deploy:
- git clone https://github.com/packpack/packpack.git packpack
- ./packpack/packpack
deploy:
provider: packagecloud
username: ${PACKAGECLOUD_USER}
repository: ${PACKAGECLOUD_REPO}
token: ${PACKAGECLOUD_TOKEN}
dist: ${OS}/${DIST}
package_glob: build/*.{deb,rpm}
skip_cleanup: true
on:
branch: master
condition: -n "${OS}" && -n "${DIST}" && -n "${PACKAGECLOUD_TOKEN}"
after_deploy:
# Prune old packages from PackageCloud, keep only the last two
- pip install -r ./packpack/tools/requirements.txt
- python ./packpack/tools/packagecloud prune ${PACKAGECLOUD_USER}/${PACKAGECLOUD_REPO} deb ${OS} ${DIST} --keep 2
- python ./packpack/tools/packagecloud prune ${PACKAGECLOUD_USER}/${PACKAGECLOUD_REPO} rpm ${OS} ${DIST} --keep 2
cache:
directories:
- $HOME/lua-5.3.2
addons:
apt:
packages:
- lua5.1
- lua5.2
- luajit
# Ubuntu Precise on Travis doesn't have lua5.3 package
install:
- |
[ -e ${HOME}/lua-5.3.2/src/lua ] || (\
wget http://www.lua.org/ftp/lua-5.3.2.tar.gz -c && \
tar xzf lua-5.3.2.tar.gz -C ${HOME} && \
make -j -C ${HOME}/lua-5.3.2 linux \
)
script:
- cd tests
- LUAJIT=`echo /usr/bin/luajit* | cut -f 1 -d ' '`
- ${LUAJIT} -v
- ${LUAJIT} runtest *.lua
- lua5.1 -v
- lua5.1 runtest *.lua
- lua5.2 -v
- lua5.2 runtest *.lua
- LUA53=${HOME}/lua-5.3.2/src/lua
- ${LUA53} -v
- ${LUA53} runtest *.lua
- cd ..
notifications:
email: true