Skip to content
Snippets Groups Projects
.gitlab-ci.yml 862 B
Newer Older
  • Learn to ignore specific revisions
  • Georg Seibt's avatar
    Georg Seibt committed
    image: openjdk:11-slim
    
    
    variables:
      GRADLE_OPTS: "-Dorg.gradle.daemon=false"
    
    before_script:
      - export GRADLE_USER_HOME=`pwd`/.gradle
    
    build:
      stage: build
      script: ./gradlew clean assemble
      cache:
        key: ${CI_COMMIT_REF_SLUG}
        policy: pull-push
        paths:
          - build
          - .gradle
    
    test:
      stage: test
      script:
        - ./gradlew --build-cache check
      cache:
        key: ${CI_COMMIT_REF_SLUG}
        policy: pull
        paths:
          - build
          - .gradle
    
    #publish release:
    #  stage: deploy
    #  script: ./gradlew --build-cache publish
    #  only:
    #    - tags
    #  cache:
    #    key: ${CI_COMMIT_REF_SLUG}
    #    policy: pull
    #    paths:
    #      - build
    #      - .gradle
    #
    #publish snapshot:
    #  stage: deploy
    #  script: ./gradlew --build-cache -Psnapshot publish
    #  cache:
    #    key: ${CI_COMMIT_REF_SLUG}
    #    policy: pull
    #    paths:
    #      - build
    
    Georg Seibt's avatar
    Georg Seibt committed
    #      - .gradle