IAP GITLAB

Skip to content
Snippets Groups Projects
.gitlab-ci.yml 1.54 KiB
Newer Older
image: corsika/devel:u-18.04
ralfulrich's avatar
ralfulrich committed

ralfulrich's avatar
ralfulrich committed
variables:
  GIT_SSL_NO_VERIFY: "1"
  ## Runtime options for sanitizers
  # (detect_leaks=0 because leak detection doesn't work in CI, but you can
  # try to test with leak detection locally by using detect_leaks=1)
  UBSAN_OPTIONS: "print_stacktrace=1"
  LSAN_OPTIONS: "log_threads=1"
  ASAN_OPTIONS: "detect_leaks=0:detect_stack_use_after_return=1"
ralfulrich's avatar
ralfulrich committed

build: # normal pipeline for each commit, except for commits to the master
  stage: build
  tags:
    - corsika
  script:
    - mkdir build
    - cd build
    - cmake .. -DCMAKE_BUILD_TYPE=Debug
    - cmake --build . -- -j4
    - ctest -j4 -V >& test.log || gzip -v -9 -S .gz test.log
  artifacts:
    expire_in: 1 year
    paths:
      - build/test.log.gz
    reports:
      junit:
        - build/test_outputs/junit*.xml
  except:
    - master
coverage: # special pipeline for master with coverage report
  stage: build
  tags:
    - corsika
  script:
    - mkdir -p build
    - cmake .. -DCMAKE_BUILD_TYPE=Coverage
    - cmake --build . -- -j4
    - cmake --build . --target coverage && tar czf coverage-report.tar.gz coverage-report
    expire_in: 1 year
      - build/coverage-report.tar.gz
ralfulrich's avatar
ralfulrich committed

ralfulrich's avatar
ralfulrich committed
  stage: build
ralfulrich's avatar
ralfulrich committed
  tags:
    - corsika
ralfulrich's avatar
ralfulrich committed
    - mkdir build
    - cd build
    - cmake ..
    - cmake --build . --target doxygen
    - mkdir .public
    - cp -r Documentation/Doxygen/html .public/
ralfulrich's avatar
ralfulrich committed
    - mv .public ../public
  artifacts:
    paths:
      - public
  only:
    - tags
    - triggers
    - schedules