From f87fcef3110679c29b69fecf8fd5b2231e888b82 Mon Sep 17 00:00:00 2001 From: "tomasz.kowalczewski" Date: Fri, 6 Nov 2020 09:53:51 +0100 Subject: [PATCH] Preparing for release to maven central. --- .circleci/.maven.xml | 9 +++++++ .circleci/config.yml | 15 ++++++++++++ pom.xml | 56 ++++++++++++++++++++++++++++++++++++++++++++ 3 files changed, 80 insertions(+) create mode 100644 .circleci/.maven.xml diff --git a/.circleci/.maven.xml b/.circleci/.maven.xml new file mode 100644 index 0000000..1228b6a --- /dev/null +++ b/.circleci/.maven.xml @@ -0,0 +1,9 @@ + + + + rso + ${env.SONATYPE_USERNAME} + ${env.SONATYPE_PASSWORD} + + + diff --git a/.circleci/config.yml b/.circleci/config.yml index 00e25cf..51b446a 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -1,5 +1,8 @@ version: 2.1 +orbs: + circleci-maven-release-orb: sonatype-nexus-community/circleci-maven-release-orb@0.0.15 + jobs: build: machine: @@ -38,8 +41,20 @@ jobs: - store_test_results: path: test-results + release: + machine: + image: ubuntu-2004:202008-01 + steps: + - checkout + - circleci-maven-release-orb/run-maven-release: + mvn-release-perform-command: 'mvn --batch-mode release:perform -DdryRun=true -s my-settings.xml' + ssh-fingerprints: 'my:ss:hf:in:ge:rp:ri:nt...' + workflows: version: 2 workflow: jobs: - build + release: + jobs: + - release diff --git a/pom.xml b/pom.xml index 6b6e9f4..249e2e4 100644 --- a/pom.xml +++ b/pom.xml @@ -38,6 +38,7 @@ UTF-8 + ${env.GPG_PASSPHRASE} 9 9 @@ -66,6 +67,20 @@ maven-javadoc-plugin 3.2.0 + + org.apache.maven.plugins + maven-source-plugin + 3.2.1 + + + maven-release-plugin + 3.0.0-M1 + + + org.apache.maven.plugins + maven-gpg-plugin + 1.6 + @@ -81,6 +96,12 @@ ${compiler.target.level} + + maven-release-plugin + + gpg-sign + + org.apache.maven.plugins maven-javadoc-plugin @@ -112,4 +133,39 @@ + + + + gpg-sign + + + + + maven-gpg-plugin + 1.6 + + + sign-artifacts + verify + + sign + + + + --pinentry-mode + loopback + + + + + + + + + ${env.GPG_PASSPHRASE} + + +