File: .travis.yml

package info (click to toggle)
node-zipfile 0.5.12%2Bds-6
  • links: PTS, VCS
  • area: main
  • in suites: bullseye
  • size: 1,044 kB
  • sloc: cpp: 508; javascript: 353; makefile: 52; sh: 29; lisp: 10
file content (105 lines) | stat: -rw-r--r-- 3,102 bytes parent folder | download | duplicates (2)
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
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
language: cpp

addons:
  apt:
    sources:
     - ubuntu-toolchain-r-test
     - llvm-toolchain-precise-3.6
    packages:
     - clang-3.6

matrix:
  include:
     # Coverage: Disabled pending migration to Codecov
     #- os: osx
       #compiler: clang
       #env: NODE_VERSION="4" COVERAGE=true # node abi 46
     # Linux
     - os: linux
       compiler: clang
       env: NODE_VERSION="10" # node abi 64
     - os: linux
       compiler: clang
       env: NODE_VERSION="9" # node abi 59
     - os: linux
       compiler: clang
       env: NODE_VERSION="8" # node abi 57
     - os: linux
       compiler: clang
       env: NODE_VERSION="7" # node abi 51
     - os: linux
       compiler: clang
       env: NODE_VERSION="6" # node abi 48
     - os: linux
       compiler: clang
       env: NODE_VERSION="4" # node abi 46
     # OS X
     - os: osx
       compiler: clang
       env: NODE_VERSION="10" # node abi 64
     - os: osx
       compiler: clang
       env: NODE_VERSION="9" # node abi 59
     - os: osx
       compiler: clang
       env: NODE_VERSION="8" # node abi 57
     - os: osx
       compiler: clang
       env: NODE_VERSION="7" # node abi 51
     - os: osx
       compiler: clang
       env: NODE_VERSION="6" # node abi 47
     - os: osx
       compiler: clang
       env: NODE_VERSION="4" # node abi 46

env:
  global:
   - JOBS: "8"

before_install:
 - scripts/validate_tag.sh
 - export COVERAGE=${COVERAGE:-false}
 - if [[ $(uname -s) == 'Linux' ]]; then
     export CXX="clang++-3.6";
     export CC="clang-3.6";
     export PYTHONPATH=$(pwd)/mason_packages/.link/lib/python2.7/site-packages;
   else
     export PYTHONPATH=$(pwd)/mason_packages/.link/lib/python/site-packages;
   fi;
 - source ./scripts/install_node.sh ${NODE_VERSION}
 - export PATH=./node_modules/.bin/:$PATH

install:
 - COMMIT_MESSAGE=$(git show -s --format=%B $TRAVIS_COMMIT | tr -d '\n')
 - if [[ ${COVERAGE} == true ]]; then
     if [[ $(uname -s) == 'Linux' ]]; then
       PYTHONUSERBASE=$(pwd)/mason_packages/.link pip install --user cpp-coveralls;
     else
       PYTHONUSERBASE=$(pwd)/mason_packages/.link easy_install --user cpp-coveralls;
     fi;
     export CXXFLAGS="--coverage";
     export LDFLAGS="--coverage";
     npm install --build-from-source --clang=1 --debug;
   else
     npm install --build-from-source --clang=1;
   fi
 - node-pre-gyp package testpackage
 - if [[ $(uname -s) == 'Linux' ]]; then
     ldd ./lib/*/*/*node;
   else
     otool -L ./lib/*/*/*node;
   fi

before_script:
 - npm test
 - if [[ ${CXX} =~ "clang" ]] && [[ ${COVERAGE} == false ]]; then
      if [[ ${COMMIT_MESSAGE} =~ "[publish binary]" ]]; then
        node-pre-gyp publish;
      elif [[ ${COMMIT_MESSAGE} =~ "[republish binary]" ]]; then
        node-pre-gyp unpublish publish;
      fi
   fi

script:
 - if [[ ${COVERAGE} == true ]]; then ./mason_packages/.link/bin/cpp-coveralls --exclude node_modules --exclude tests --build-root build --gcov-options '\-lp' --exclude tools --exclude docs --exclude sdk --exclude build/Release/obj/gen --exclude src/node_zipfile.hpp --exclude deps > /dev/null; fi;