.gitlab-ci.yml 5.48 KB
Newer Older
1
stages:
2
  - check
3
4
5
6
7
8
9
10
  - build
  - documentation
  
CbmRoot_Continuous:
  stage: build
  tags:
    - CbmRoot
  only:
Administrator's avatar
Administrator committed
11
12
    refs:
      - master
13
    variables:
Administrator's avatar
Administrator committed
14
      - $CI_PROJECT_PATH == "computing/cbmroot"
15
16
17
  cache:
    paths:
      - build/
Administrator's avatar
Administrator committed
18
19
      - external/AnalysisTree/
      - external/AnaylysisTreeQA/
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
      - external/DataTree/
      - external/DataTreeQA/
      - external/KFParticle/
      - external/NicaFemto/
      - external/Vc/
      - external/cppzmq/
      - external/flib_dpb/flib_dpb/
      - external/flib_dpb_20/
      - external/ipc/ipc/
      - external/ipc_legacy/ipc/
      - external/jsroot/
      - external/spadic/spadic/
      - input
      - geometry
      - parameters
  script:
    - set -xv
    - mkdir -p build 
    - cd build
    - find . -name "*.root" -delete
    - find . -name "*_ok" -delete
    - find . -name "all_*.par" -delete
    - cd ..
    - echo "export LINUX_FLAVOUR=Debian8.11" >> Dart.cfg
    - echo "export FAIRSOFT_VERSION=jun19p1" >> Dart.cfg
    - echo "export FAIRROOT_VERSION=v18.2.0" >> Dart.cfg
    - echo "export SIMPATH=/cvmfs/fairroot.gsi.de/fairsoft/\${FAIRSOFT_VERSION}" >> Dart.cfg
Administrator's avatar
Administrator committed
47
    - echo "export FAIRROOTPATH=/cvmfs/fairroot.gsi.de/fairroot/\${FAIRROOT_VERSION}_fairsoft-\${FAIRSOFT_VERSION}" >> Dart.cfg
48
49
50
51
52
53
54
55
56
57
58
59
60
61
    - echo "export BUILDDIR=$PWD/build" >> Dart.cfg
    - echo "export SOURCEDIR=$PWD" >> Dart.cfg
    - echo "export NCPU=5" >> Dart.cfg
    - echo "export PATH=\$SIMPATH/bin:$PATH" >> Dart.cfg
    - ls
    - pwd
    - cat Dart.cfg
    - $PWD/Dart.sh Continuous Dart.cfg
    - cd build
    - find . -name "*.root" -delete
    - find . -name "*_ok" -delete
    - find . -name "all_*.par" -delete
    - cd ..

Administrator's avatar
Administrator committed
62
63
64
65
66
67
68
69
FormatCheck:
  stage: check
  tags:
    - CbmRoot
  only:
    refs:
      - merge_requests
    variables:
Administrator's avatar
Administrator committed
70
      - $CI_MERGE_REQUEST_PROJECT_PATH == "computing/cbmroot" && $CI_MERGE_REQUEST_TARGET_BRANCH_NAME == "master"
Administrator's avatar
Administrator committed
71
  script:
Administrator's avatar
Administrator committed
72
73
74
75
    # Get the upstream repository manually. I did not find any other way to have it for
    # comparisson
    - scripts/connect_upstream_repo.sh $CI_MERGE_REQUEST_PROJECT_URL
    - git fetch upstream
Administrator's avatar
Administrator committed
76
77
78
79
80
81
82
83
    - echo "export FAIRSOFT_VERSION=jun19p1" > env.sh
    - echo "export FAIRROOT_VERSION=v18.2.0" >> env.sh
    - echo "export SIMPATH=/cvmfs/fairroot.gsi.de/fairsoft/\${FAIRSOFT_VERSION}" >> env.sh
    - echo "export FAIRROOTPATH=/cvmfs/fairroot.gsi.de/fairroot/\${FAIRROOT_VERSION}_fairsoft-\${FAIRSOFT_VERSION}" >> env.sh
    - echo "export BUILDDIR=$PWD/build" >> env.sh
    - echo "export SOURCEDIR=$PWD" >> env.sh
    - echo "export PATH=/cvmfs/fairroot.gsi.de/clang-format-8.0.1:\$SIMPATH/bin:$PATH:/cvmfs/it.gsi.de/compiler/llvm/6.0.1/bin/" >> env.sh
    - echo "export LABEL=format-check_MR-\${CI_MERGE_REQUEST_IID}" >> env.sh
Administrator's avatar
Administrator committed
84
    - echo "export FAIRROOT_FORMAT_BASE=upstream/\${CI_MERGE_REQUEST_TARGET_BRANCH_NAME}" >> env.sh
Administrator's avatar
Administrator committed
85
    - . ./env.sh && ctest -S cmake/scripts/checkformat.cmake -VV
86
87
88
89
90

CbmRoot_Merge:
  stage: build
  tags:
    - CbmRoot
91
92
93
94
  only:
    refs:
      - merge_requests
    variables:
Administrator's avatar
Administrator committed
95
      - $CI_MERGE_REQUEST_PROJECT_PATH == "computing/cbmroot" && $CI_MERGE_REQUEST_TARGET_BRANCH_NAME == "master"
96
  script:
Administrator's avatar
Administrator committed
97
98
    - echo $CI_MERGE_REQUEST_SOURCE_PROJECT_PATH
    - echo $CI_MERGE_REQUEST_PROJECT_PATH
99
100
101
102
    - if [ "$CI_MERGE_REQUEST_PROJECT_PATH" != "computing/cbmroot" ]; then
    -   echo "Should not come here"
    -   exit 1
    - fi
Administrator's avatar
Administrator committed
103
104
105
    - echo $CI_MERGE_REQUEST_TARGET_BRANCH_NAME
    - echo $CI_MERGE_REQUEST_ID
    - echo $CI_MERGE_REQUEST_IID
106
107
108
109
110
111
112
113
114
115
116
117
    - echo "export LINUX_FLAVOUR=Debian8.11" >> Dart.cfg
    - echo "export FAIRSOFT_VERSION=jun19p1" >> Dart.cfg
    - echo "export FAIRROOT_VERSION=v18.2.0" >> Dart.cfg
    - echo "export SIMPATH=/cvmfs/fairroot.gsi.de/fairsoft/\${FAIRSOFT_VERSION}" >> Dart.cfg
    - echo "export FAIRROOTPATH=/cvmfs/fairroot.gsi.de/fairroot/\${FAIRROOT_VERSION}_fairsoft-\${FAIRSOFT_VERSION}" >> Dart.cfg 
    - echo "export BUILDDIR=$PWD/build" >> Dart.cfg
    - echo "export SOURCEDIR=$PWD" >> Dart.cfg
    - echo "export NCPU=5" >> Dart.cfg
    - echo "export PATH=\$SIMPATH/bin:$PATH" >> Dart.cfg
    - ls
    - pwd
    - cat Dart.cfg
Administrator's avatar
Administrator committed
118
    - $PWD/Dart.sh MergeRequest Dart.cfg
119

120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
CbmRoot_Merge_macosx:
  stage: build
  tags:
    - CbmRoot_macosx
  only:
    refs:
      - merge_requests
    variables:
      - $CI_MERGE_REQUEST_PROJECT_PATH == "computing/cbmroot" && $CI_MERGE_REQUEST_TARGET_BRANCH_NAME == "master"
  script:
    - echo $CI_MERGE_REQUEST_SOURCE_PROJECT_PATH
    - echo $CI_MERGE_REQUEST_PROJECT_PATH
    - if [ "$CI_MERGE_REQUEST_PROJECT_PATH" != "computing/cbmroot" ]; then
    -   echo "Should not come here"
    -   exit 1
    - fi
    - echo $CI_MERGE_REQUEST_TARGET_BRANCH_NAME
    - echo $CI_MERGE_REQUEST_ID
    - echo $CI_MERGE_REQUEST_IID
    - echo "export LINUX_FLAVOUR=macOS_10.13" >> Dart.cfg
    - echo "export FAIRSOFT_VERSION=jun19p1" >> Dart.cfg
    - echo "export FAIRROOT_VERSION=v18.2.0" >> Dart.cfg
    - echo "export SIMPATH=/opt/fairsoft/\${FAIRSOFT_VERSION}" >> Dart.cfg
    - echo "export FAIRROOTPATH=/opt/fairroot/\${FAIRROOT_VERSION}_fairsoft-\${FAIRSOFT_VERSION}" >> Dart.cfg
    - echo "export BUILDDIR=$PWD/build" >> Dart.cfg
    - echo "export SOURCEDIR=$PWD" >> Dart.cfg
    - echo "export NCPU=4" >> Dart.cfg
    - echo "export PATH=\$SIMPATH/bin:$PATH" >> Dart.cfg
    - ls
    - pwd
    - cat Dart.cfg
    - $PWD/Dart.sh MergeRequest Dart.cfg

153
154
155
156
157
158
159
160
161
162
163
164
165
166
pages:
  stage: documentation
  image: alpine
  tags:
    - docker
  script:
    - apk update && apk add doxygen
    - doxygen doxygen/cbmDoxyfile.conf
    - mv html-doc/html public/
  artifacts:
    paths:
      - public
  only:
    - doxygen