This repository has been archived by the owner on Sep 17, 2020. It is now read-only.
-
-
Notifications
You must be signed in to change notification settings - Fork 38
/
.travis.yml
72 lines (65 loc) · 2.03 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
matrix:
include:
- os: linux
language: node_js
node_js:
- "10"
- os: osx
osx_image: xcode10.2
language: node_js
node_js:
- "10"
env:
global:
- ARTIFACTS_TARGET_PATHS="electron-player/$TRAVIS_BRANCH"
addons:
artifacts:
paths:
- $(ls webrecorder-player-*{dmg,AppImage})
before_install:
- |
if [[ $TRAVIS_OS_NAME == 'linux' ]]; then
sed -i'' -E 's/"name": "(.*)"/"name": "\1-linux"/' ./package.json
apt-get -qq update;
sudo apt-get install -y icnsutils graphicsmagick;
FLASH_PLUGIN="https://s3.amazonaws.com/webrecorder-builds/flashplugin/libpepflashplayer.so";
cd plugins;
wget $FLASH_PLUGIN;
cd -;
fi
- |
if [[ $TRAVIS_OS_NAME == 'osx' ]]; then
sed -i '' -E 's/"name": "(.*)"/"name": "\1-osx"/' ./package.json
FLASH_PLUGIN="https://s3.amazonaws.com/webrecorder-builds/flashplugin/PepperFlashPlayer.plugin.zip";
cd plugins;
wget $FLASH_PLUGIN;
unzip PepperFlashPlayer.plugin.zip;
rm PepperFlashPlayer.plugin.zip;
cd -;
fi
install:
- BUCKET="https://s3.amazonaws.com/webrecorder-builds/webrecorder-player"
- CURRENT_BRANCH="$BUCKET/$TRAVIS_BRANCH/webrecorder-player-$TRAVIS_OS_NAME"
- DEVELOP_BRANCH="$BUCKET/develop/webrecorder-player-$TRAVIS_OS_NAME"
- |
if curl -o /dev/null -s -I -f "$CURRENT_BRANCH"; then
echo "downloading webrecorder artifact: $CURRENT_BRANCH";
curl -o python-binaries/webrecorder_player $CURRENT_BRANCH;
else
echo "downloading webrecorder artifact: $DEVELOP_BRANCH";
curl -o python-binaries/webrecorder_player $DEVELOP_BRANCH;
fi
- chmod +x python-binaries/webrecorder_player
- python-binaries/webrecorder_player -v
- yarn install
- yarn run build
after_failure:
- cat ~/.npm/_logs/*.log
script:
- |
if [[ $TRAVIS_BRANCH == 'master' || $TRAVIS_BRANCH == 'prerelease' ]]; then
yarn run release
else
yarn run dist
fi
- mv ./dist/webrecorder-player-* $TRAVIS_BUILD_DIR/