Skip to content

Commit

Permalink
[circleci] Sync releases with mavencentral (#234)
Browse files Browse the repository at this point in the history
Currently, the JMXFetch releases are only put on bintray.
Adds a step in the deploy job that uses bintray's "Sync with
Maven Central" feature to also release JMXFetch on Maven Central.
  • Loading branch information
KSerrania authored Jun 17, 2019
1 parent b0a78a2 commit 6fc84c1
Showing 1 changed file with 12 additions and 2 deletions.
14 changes: 12 additions & 2 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -59,8 +59,18 @@ jobs:
- attach_workspace:
at: .

- run: mvn validate jar:jar source:jar javadoc:jar assembly:single deploy:deploy -e --settings ./settings.xml

- run:
name: Deploy to bintray
command: mvn validate jar:jar source:jar javadoc:jar assembly:single deploy:deploy -e --settings ./settings.xml
- run:
name: Sync with mavencentral
command: |
VERSION=$(mvn help:evaluate -Dexpression=project.version -q -DforceStdout)
curl -X POST -H "Content-Type: application/json" \
--user ${BINTRAY_USER}:${BINTRAY_API_KEY} \
--data "{\"username\":\"${SONATYPE_USER}\", \"password\":\"${SONATYPE_PWD}\"}" \
https://api.bintray.com/maven_central_sync/datadog/datadog-maven/jmxfetch/versions/$VERSION
workflows:
version: 2
build_test_deploy:
Expand Down

0 comments on commit 6fc84c1

Please sign in to comment.