.gitlab-ci.yml 959 Bytes
Newer Older
1 2
image: maven:alpine

3 4
variables:
  # Put the m2 repository into the cached m2-repository directory volume to save time and bandwidth.
Marco Konersmann's avatar
Marco Konersmann committed
5
  # This will also suppress any download for dependencies and plugins or upload messages which would clutter the console log.
6
  # `showDateTime` will show the passed time in milliseconds. You need to specify `--batch-mode` to make this work.
7
  MAVEN_OPTS: "-Dmaven.repo.local=/m2-repository -Dorg.slf4j.simpleLogger.showDateTime=true -Djava.awt.headless=true"
8
  MAVEN_CLI_OPTS: "--batch-mode --errors --fail-at-end --show-version -DinstallAtEnd=true -DdeployAtEnd=true"
9

10 11 12 13 14 15 16
stages:
  - build
  - test

build:
  stage: build
  script:
17
    - mvn -DskipTests package $MAVEN_CLI_OPTS
18 19
  artifacts:
    paths:
20
    - "Build/p2updatesite/target/repository"
21 22 23 24

test:
  stage: test
  script:
25
    - mvn verify findbugs:findbugs site -Ptest $MAVEN_CLI_OPTS
26 27
  artifacts:
    paths:
28 29
      - "**/target/surefire-reports"
      - "**/target/site"