Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* feat(pom-release-published.yml): add workflow for releasing extension to Sonatype Maven Central Repository This commit adds a new workflow file `pom-release-published.yml` that is triggered when a workflow call event occurs. The workflow is triggered by the caller workflow and requires the `SONATYPE_USERNAME` and `SONATYPE_TOKEN` secrets to be provided. The `release` job in the workflow runs on the `ubuntu-latest` environment and performs the following steps: 1. Checks out the repository using `actions/checkout@v3`. 2. Sets up Java for publishing to the Maven Central Repository using `actions/setup-java@v3`. The Java version is set to `17` and the distribution is set to `temurin`. The Maven cache is also configured. 3. Configures Git with the username and email. 4. Builds the release artifacts using Maven. The `release:clean` and `release:prepare` goals are executed with the necessary arguments. The release version is obtained from the `liquibaseVersion` input provided by the caller workflow. The changes are not pushed to the remote repository. 5. Retrieves the artifact ID from the Maven project and sets it as an environment variable. 6. Downloads the release artifacts using `robinraju/release-downloader@v1.6`. The artifacts are downloaded based on the tag name and the artifact ID. 7. Publishes the artifacts to the Maven Central Repository using the `maven-deploy-plugin`. The Maven username and password are obtained from the `SONATYPE_USERNAME` and `SONATYPE_TOKEN` secrets respectively. The POM file and its associated files are deployed to the Sonatype Nexus staging repository. The `maven-release` job is dependent on the `release` job and uses the `liquibase/build-logic/.github/workflows/extension-release-prepare.yml@v0.4.2` action. The secrets are inherited from the `release` job. No newline at end of file. * chore(README.md): add new workflow `pom-release-published.yml` to the table The `pom-release-published.yml` workflow is responsible for publishing a release pom to Maven Central. This workflow is added to the table of reusable workflows in the README.md file to provide visibility and documentation for this new workflow. * chore(pom-release-published.yml): remove unnecessary line break and trailing whitespace for better readability chore(pom-release-published.yml): remove unused parameters in maven-release step to simplify the command * fix(pom-release-published.yml): add missing file and classifiers options to maven deploy command The maven deploy command was missing the file and classifiers options, which caused the pom.asc file to not be deployed. This commit adds the missing options to ensure that the pom.asc file is included in the deployment. * fix(pom-release-published.yml): remove unnecessary options from maven deploy command The options `-Dfiles`, `-Dtypes`, and `-Dclassifiers` were removed from the maven deploy command as they were not needed. * fix(pom-release-published.yml): add additional parameters to the Maven deploy command to include the .asc file for GPG signature feat(pom-release-published.yml): add a new job 'maven-release' that depends on the 'release' job * fix(pom-release-published.yml): remove unnecessary options from maven deploy command The options `-Dfiles=${{ env.artifact_id }}-${version}.pom.asc`, `-Dtypes=asc`, and `-Dclassifiers=asc` were removed from the maven deploy command as they are unnecessary and do not affect the deployment process. * fix(pom-release-published.yml): add the generated POM.asc file to the Maven release command to include it in the release artifacts * chore(pom-release-published.yml): add classifiers option to maven-release step to include pom.asc file in the release artifacts * fix(pom-release-published.yml): remove the 'classifiers' argument from the Maven command to fix an issue with releasing the POM file * fix(pom-release-published.yml): fix the file name in the -Dfiles parameter to include the file extension fix(pom-release-published.yml): add the pom.asc classifier to the -Dclassifiers parameter to include the asc file in the deployment * fix(pom-release-published.yml): fix the file name in the -Dfiles parameter to include the .pom extension fix(pom-release-published.yml): fix the -Dclassifiers parameter value to be 'asc' instead of 'pom.asc' * fix(pom-release-published.yml): remove unnecessary classifier value in maven-release step The classifier value in the maven-release step was set to a comma (,) which is unnecessary. This commit removes the classifier value to improve the clarity and correctness of the workflow. * fix(pom-release-published.yml): fix missing backslash at the end of line 58 to properly escape the line continuation fix(pom-release-published.yml): fix missing comma in line 62 to separate classifiers * fix(pom-release-published.yml): add a missing backslash to the end of the line to properly continue the command on the next line * fix(pom-release-published.yml): remove unnecessary configuration for generating pom.asc file during release The configuration for generating the pom.asc file was removed as it is not needed for the release process. * fix(pom-release-published.yml): change maven-deploy-plugin command from deploy-file to deploy to match the correct plugin goal * chore(pom-release-published.yml): update workflow name to accurately reflect its purpose feat(pom-release-published.yml): add support for deploying additional files (sources, javadoc, and signatures) to Sonatype repository for better artifact management
- Loading branch information