From 8c7758d501259b1d9247df7e1e7d008054316b4f Mon Sep 17 00:00:00 2001 From: Georgios Andrianakis Date: Mon, 28 Oct 2024 14:23:11 +0200 Subject: [PATCH] Bring back automatic version update in samples --- .github/workflows/release-perform.yml | 26 ++++++++++++++++++++------ 1 file changed, 20 insertions(+), 6 deletions(-) diff --git a/.github/workflows/release-perform.yml b/.github/workflows/release-perform.yml index 9f74cb4c7..6e99dd32e 100644 --- a/.github/workflows/release-perform.yml +++ b/.github/workflows/release-perform.yml @@ -21,9 +21,23 @@ concurrency: jobs: perform-release: - name: Perform Release - uses: quarkiverse/.github/.github/workflows/perform-release.yml@main - secrets: inherit - with: - version: ${{github.event.inputs.tag || github.ref_name}} - java_version: 23 + steps: + - name: Perform Release + uses: quarkiverse/.github/.github/workflows/perform-release.yml@main + secrets: inherit + with: + version: ${{github.event.inputs.tag || github.ref_name}} + java_version: 23 + + - name: Update dependency versions for the samples + run: | + while IFS= read -r -d '' pom + do + ./mvnw org.codehaus.mojo:versions-maven-plugin:2.16.2:set-property -Dproperty=quarkus-langchain4j.version -DnewVersion=${{steps.metadata.outputs.current-version}} -f "$(dirname "$pom")"; + done < <(find samples/ -name pom.xml -print0) + git commit -a -m "Update dependencies in samples" + + - name: Push changes to ${{github.base_ref}} branch + run: | + git push + git push origin ${{steps.metadata.outputs.current-version}}