Skip to content

Commit

Permalink
Merge pull request #1035 from quarkiverse/release_wf_fix
Browse files Browse the repository at this point in the history
Moving samples updates to release-prepare.yml
  • Loading branch information
geoand authored Nov 1, 2024
2 parents 56fc260 + ffc7590 commit 9df1be6
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 47 deletions.
5 changes: 5 additions & 0 deletions .github/workflows/hooks/pre-prepare-release.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
while IFS= read -r -d '' pom
do
./mvnw org.codehaus.mojo:versions-maven-plugin:2.16.2:set-property -Dproperty=quarkus-langchain4j.version -DnewVersion=${CURRENT_VERSION} -f "$(dirname "$pom")";
done < <(find samples/ -name pom.xml -print0)
git commit -a -m "Update dependencies in samples"
47 changes: 0 additions & 47 deletions .github/workflows/release-perform.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,50 +27,3 @@ jobs:
with:
version: ${{github.event.inputs.tag || github.ref_name}}
java_version: 23

post-release:
name: Post release tasks
runs-on: ubuntu-latest
steps:
- uses: actions/create-github-app-token@v1
id: app-token
name: Create GitHub App Token
with:
app-id: ${{ vars.CI_APP_ID }}
private-key: ${{ secrets.CI_APP_PRIVATE_KEY }}

- uses: actions/checkout@v4
with:
token: ${{ steps.app-token.outputs.token }}

- name: Get GitHub App User ID
id: get-user-id
run: echo "user-id=$(gh api "/users/${{ steps.app-token.outputs.app-slug }}[bot]" --jq .id)" >> "$GITHUB_OUTPUT"
env:
GH_TOKEN: ${{ steps.app-token.outputs.token }}

- name: Configure Git author
run: |
git config --global user.name '${{ steps.app-token.outputs.app-slug }}[bot]'
git config --global user.email '${{ steps.get-user-id.outputs.user-id }}+${{ steps.app-token.outputs.app-slug }}[bot]@users.noreply.github.com>'
- uses: radcortez/project-metadata-action@main
name: Retrieve project metadata
id: metadata
with:
github-token: ${{secrets.GITHUB_TOKEN}}
metadata-file-path: '.github/project.yml'
local-file: true

- 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}}

0 comments on commit 9df1be6

Please sign in to comment.