Skip to content

Commit

Permalink
Replace Version using sed instead of yq
Browse files Browse the repository at this point in the history
yq does not preserve formatting with in place writing, see mikefarah/yq#465
  • Loading branch information
marcusdacoregio committed May 3, 2024
1 parent b5124cf commit 2a3989f
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions .github/workflows/update-antora-ui-spring.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,12 +33,11 @@ jobs:
shell: bash
env:
GH_TOKEN: ${{ secrets.token }}
- name: Replace Version
uses: mikefarah/[email protected]
- name: Replace Current with Latest
id: replace
if: ${{ steps.current.outputs.result != steps.latest.outputs.latest_ui_bundle_url }}
with:
cmd: yq -i '.ui.bundle.url = "${{ steps.latest.outputs.latest_ui_bundle_url }}"' antora-playbook.yml
run: |
sed -i '' -e 's@${{ steps.current.outputs.result }}@${{ steps.latest.outputs.latest_ui_bundle_url }}@g' antora-playbook.yml
- name: Create Pull Request
uses: peter-evans/create-pull-request@v6
with:
Expand Down

0 comments on commit 2a3989f

Please sign in to comment.