File tree Expand file tree Collapse file tree 3 files changed +51
-11
lines changed
Expand file tree Collapse file tree 3 files changed +51
-11
lines changed Original file line number Diff line number Diff line change 1+ conditions : v1
2+ sudo : required
3+ dist : xenial
14language : node_js
25node_js :
3- - 0.8
6+ - ' 12 '
47
5- before_script :
8+ addons :
9+ chrome : stable
10+
11+ services :
12+ - xvfb
13+ cache :
14+ directories :
15+ - node_modules
16+
17+ before_install :
618 - export DISPLAY=:99.0
7- - sh -e /etc/init.d/xvfb start
8- - npm install --quiet -g karma
9- - ./scripts/web-server.js > /dev/null &
10- - sleep 1 # give server time to start
11-
12- script :
13- - karma start config/karma.conf.js --no-auto-watch --single-run --reporters=dots --browsers=Firefox
14- - karma start config/karma-e2e.conf.js --reporters=dots --browsers=Firefox
19+ - chmod +x ./scripts/travis.sh
20+
21+ script : ./scripts/travis.sh
22+
23+ stages :
24+ - Release
25+
26+ jobs :
27+ fast_finish : true
28+ include :
29+ # https://docs.travis-ci.com/user/build-stages/deploy-github-releases/
30+ - stage : Release
31+ name : ' Releasing a new version'
32+ if : tag IS present
33+ deploy :
34+ - provider : releases
35+ api_key : $GH_TOKEN
36+ file_glob : true
37+ file : _dist/*.zip
38+ skip_cleanup : true
39+ on :
40+ tags : true
Original file line number Diff line number Diff line change 3232 "grunt-contrib-watch" : " ~0.5.3"
3333 },
3434 "scripts" : {
35- "test" : " echo \" Error: no test specified\" && exit 1"
35+ "test" : " echo \" Error: no test specified\" && exit 1" ,
36+ "build" : " grunt && npm run create:zip" ,
37+ "create:zip" : " cd _dist && zip -r studio_$TAG.zip ."
3638 },
3739 "repository" : {
3840 "type" : " git" ,
Original file line number Diff line number Diff line change 1+ #! /bin/sh
2+ # https://docs.travis-ci.com/user/customizing-the-build/#Implementing-Complex-Build-Steps
3+ set -ev
4+ npm install grunt
5+ if [ " ${TRAVIS_MODE} " = " release" ]; then
6+ echo " Building..."
7+ TAG=$TRAVIS_TAG yarn run build
8+ echo " Finish building"
9+ else
10+ echo " Unknown travis mode: ${TRAVIS_MODE} " 1>&2
11+ exit 1
12+ fi
You can’t perform that action at this time.
0 commit comments