From 371e368d9841b098a2077fe9dd6c5b7199c38b93 Mon Sep 17 00:00:00 2001 From: Chris Allan Date: Wed, 20 May 2020 09:32:57 +0100 Subject: [PATCH] Publish artifacts to Nexus --- appveyor.yml | 11 +++++++++-- build.gradle | 19 +++++++++++++++++++ 2 files changed, 28 insertions(+), 2 deletions(-) diff --git a/appveyor.yml b/appveyor.yml index f5a16b49..bd291ebb 100644 --- a/appveyor.yml +++ b/appveyor.yml @@ -1,11 +1,17 @@ version: 0.2.3.{build} +environment: + ARTIFACTORY_USERNAME: + secure: ZVwlgtk8NtZWeEqpYjR9d8NXeX+xMnuCzgITBKRhtD8= + ARTIFACTORY_PASSWORD: + secure: O6ThMzLvtSOPLV0U5yFOkl8G1tFrFOGZEpKI4NSD12c= + image: Ubuntu stack: jdk 11 install: - - sh: sudo apt-get update - - sh: sudo apt-get install -y libblosc1 + - sh: sudo apt-get update + - sh: sudo apt-get install -y libblosc1 build: off @@ -14,6 +20,7 @@ build_script: after_test: - ./gradlew distZip + - if [ -z "$APPVEYOR_PULL_REQUEST_NUMBER" ]; then ./gradlew -PArtifactoryUserName=${ARTIFACTORY_USERNAME} -PArtifactoryPassword=${ARTIFACTORY_PASSWORD} publish; fi artifacts: - path: 'build\distributions\*.zip' diff --git a/build.gradle b/build.gradle index 91760fdd..e0bf6c81 100644 --- a/build.gradle +++ b/build.gradle @@ -1,6 +1,7 @@ plugins { id 'application' id 'eclipse' + id 'maven-publish' id 'checkstyle' } @@ -58,6 +59,24 @@ distributions { } } +publishing { + publications { + bioformats2raw(MavenPublication) { + from components.java + } + } + + repositories { + maven { + url 'https://repo.glencoesoftware.com/repository/bioformats2raw2ometiff/' + credentials { + username = project.properties.ArtifactoryUserName + password = project.properties.ArtifactoryPassword + } + } + } +} + checkstyle { toolVersion = "8.26" }