Skip to content

Maintenance instructions

Andrew Guibert edited this page Feb 8, 2020 · 5 revisions

Releasing a new version

In this example, suppose the latest release is 0.4.1 and the project is currently at version 0.4.2-SNAPSHOT. We will be performing a release of version 0.4.2 and then updating the project to version 0.4.3-SNAPSHOT.

  1. Ensure you have completed the one-time setup steps
  2. Update artifacts to the version to be released:
    ./gradlew updateVersion -PnextVersion=0.4.2
    
  3. Publish release artifacts to maven central staging:
    ./gradlew publish
    
  4. Log in to your Sonatype account at https://oss.sonatype.org/
  5. Go to the Staging Repositories tab and refresh. You will see a staging repo ID such as orgmicroshed-1011
  6. To test the new release in staging, add the following repository config:
    <repositories>
       <repository>
           <id>sonatype-staging</id>
           <url>https://oss.sonatype.org/service/local/repositories/${STAGING_REPO_ID}/content/</url>
       </repository>
    </repositories>
  7. If the new release test out OK, press the Close button to close the staging repository.
  8. Press the Release button to release the artifacts to Maven Central.
  9. Draft a new release on Github: https://github.com/MicroShed/microshed-testing/releases
  10. Update to the next development snapshot version and make a PR with the changes:
    ./gradlew updateVersion -PnextVersion=0.4.3-SNAPSHOT
    

One-time setup

  1. Create a file at ~/.gradle/gradle.properties with the contents:
    # See this doc for how to obtain these values:
    # https://docs.gradle.org/current/userguide/signing_plugin.html#sec:signatory_credentials
    signing.keyId=...
    signing.password=...
    signing.secretKeyRingFile=/path/to/home/.gnupg/secring.gpg
    
    sonatypeUsername=...
    sonatypePassword=...
    
    ossrhUsername=...
    ossrhPassword=...
    

Checking for dependency updates

Dependency updates to source modules should happen automatically via Dependabot PRs. If you want to perform additional checking, you can run the ./gradlew dependencyUpdates -Drevision=release task.

Clone this wiki locally