Skip to content

Commit

Permalink
Clone wp post
Browse files Browse the repository at this point in the history
  • Loading branch information
Leonardo Mendoza Fernadez authored and Leonardo Mendoza Fernadez committed May 7, 2024
1 parent af09688 commit ee5dc49
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions .github/workflows/clone-post.yml
Original file line number Diff line number Diff line change
Expand Up @@ -46,16 +46,16 @@ jobs:
# Check if there are any changes
if git diff --staged --quiet; then
echo "No changes to commit."
echo "should_run='false'" >> "$GITHUB_OUTPUT"
echo "should-run=false" >> "$GITHUB_OUTPUT"
else
git commit -m "Cloned WordPress post ${{ github.event.inputs.postID }} for environment ${{ github.event.inputs.environment }}"
git push;
echo "should_run='true'" >> "$GITHUB_OUTPUT"
echo "should-run=true" >> "$GITHUB_OUTPUT"
fi
- name: Debug output
run: |
echo "$Github_output file contents: " && cat "$GITHUB_OUTPUT"
echo needs.commit_changes.outputs.should_run: ${{ needs.commit_changes.outputs.should_run }}
echo needs.commit_changes.outputs.should-run: ${{ steps.commit_changes.outputs.should-run }}
env:
GITHUB_OUTPUT: ${{ github.workspace }}/output.txt
continue-on-error: true
Expand All @@ -64,7 +64,7 @@ jobs:
release_new_version:
runs-on: ubuntu-latest
needs: clone_post
if: needs.commit_changes.outputs.should_run == 'true'
if: steps.commit_changes.outputs.should-run == 'true'
steps:
- name: Exit if no relevant changes
run: echo "Exiting because there are no changes in src" && exit 0
Expand Down Expand Up @@ -108,7 +108,7 @@ jobs:


upload_to_s3:
if: needs.commit_changes.outputs.should_run == 'true'
if: needs.commit_changes.outputs.should-run == 'true'
needs: release_new_version
runs-on: ubuntu-latest
steps:
Expand Down

0 comments on commit ee5dc49

Please sign in to comment.