Continuous Integration
Continuous integration for the AsciidoctorJ project is performed by GitHub Actions. You can find recent build results, including the build status of pull requests, on the asciidoctor/asciidoctorj page.
Release and publish the artifacts
To build and publish a release the following properties have to be set, for example in the file ~/.gradle/gradle.properties:
signing.keyId=... (1)
signing.password=...
signing.secretKeyRingFile=/home/YOUR_USERNAME/.gnupg/secring.gpg
sdkman_consumer_key=... (2)
sdkman_consumer_token=...
sonatypeUsername=... (3)
sonatypePassword=...
1 | Settings for signing the artifacts |
2 | Credentials for publishing a new release to sdkman |
3 | Credentials for publishing artifacts to oss.sonatype.org |
The following steps are necessary to build a new release:
-
Update the version in gradle.properties to a release version, i.e. from
2.4.4-SNAPSHOT
to2.4.4
. -
Build the release with
# ./gradlew clean build
-
After testing publish all artifacts to a local repository under
build/repos
with# ./gradlew publishAllPublicationsToLocalRepository -i
-
When everything is fine publish the artifacts to a staging repository on oss.sonatype.org and close the repository:
# ./gradlew publishAllPublicationsToSonatypeRepository -i # ./gradlew closeRepository -i
-
Visit oss.sonatype.org/#stagingRepositories and check the staging repository. The artifacts are not published yet. The repository URL shown there can be used for testing this version before publishing to Maven central.
-
When everything is fine publish the artifacts in the staging repository by clicking the "Release" button. Alternatively you can release it with
# ./gradlew releaseRepository
-
Publish the new version to sdkman with
# ./gradlew asciidoctorj-distribution:sdkMajorRelease
-
Commit everything and assign a tag:
# git commit -m "Release v2.x.y" # git tag v2.x.y
-
Upgrade the version to the next version by changing the version property in gradle.properties to
version=2.x.y+1-SNAPSHOT
and commit:git commit -m "Prepare next release"