.gitlab-ci.yml 1.8 KB
Newer Older
alexander.weigl's avatar
alexander.weigl committed
1 2
image: key-ant-openjdk-8:latest

alexander.weigl's avatar
alexander.weigl committed
3 4 5 6 7
cache:
  paths:
    - .m2/

variables:
Alexander Weigl's avatar
Alexander Weigl committed
8 9 10 11
  MAVEN_OPTS: >-
    -Dmaven.repo.local=${CI_PROJECT_DIR}/.m2
    -Dorg.slf4j.simpleLogger.log.org.apache.maven.cli.transfer.Slf4jMavenTransferListener=WARN
    -Dorg.slf4j.simpleLogger.showDateTime=true
12
  GIT_SSL_NO_VERIFY: "true"
13

Alexander Weigl's avatar
Alexander Weigl committed
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
stages:
  - setup
  - build
  - test
  - deploy

setup:
  script: >
    COMPONENTS=keydeps/lib/components/
    mvn install:install-file -Dfile=$COMPONENTS/key.core.jar \
                               -DgroupId=key-project-psdbg \
                               -DartifactId=key.core \
                               -Dversion=2.7-SNAPSHOT \
                               -Dpackaging=jar

    mvn install:install-file -Dfile=$COMPONENTS/key.ui.jar \
                               -DgroupId=key-project-psdbg \
                               -DartifactId=key.ui \
                               -Dversion=2.7-SNAPSHOT \
                               -Dpackaging=jar

    mvn install:install-file -Dfile=$COMPONENTS/key.util.jar \
                               -DgroupId=key-project-psdbg \
                               -DartifactId=key.util \
                               -Dversion=2.7-SNAPSHOT \
                               -Dpackaging=jar

    mvn install:install-file -Dfile=$COMPONENTS/../libs/recoderKey.jar\
                               -DgroupId=key-project-psdbg \
                               -DartifactId=recoder \
                               -Dversion=2.7\
                               -Dpackaging=jar

alexander.weigl's avatar
alexander.weigl committed
47

alexander.weigl's avatar
alexander.weigl committed
48
build:
Alexander Weigl's avatar
Alexander Weigl committed
49
  stage: build
alexander.weigl's avatar
alexander.weigl committed
50 51
  script: "mvn compile -B -T 2"

Alexander Weigl's avatar
Alexander Weigl committed
52 53
test:
  stage: test
alexander.weigl's avatar
alexander.weigl committed
54 55
  script: "mvn test -B"

alexander.weigl's avatar
alexander.weigl committed
56
deploy:
Alexander Weigl's avatar
Alexander Weigl committed
57
  stage: deploy
alexander.weigl's avatar
alexander.weigl committed
58
  script: 
Alexander Weigl's avatar
Alexander Weigl committed
59
    - "mvn package -DperformRelease=true -DcreateChecksum=true -DskipTests=true -B"
alexander.weigl's avatar
alexander.weigl committed
60 61 62
  artifacts: 
    paths:
      - target/*jar
alexander.weigl's avatar
alexander.weigl committed
63 64
      - target/site/*
  allow_failure: true