Skip to content

Commit

Permalink
chore(actions): Use plumbing git commands
Browse files Browse the repository at this point in the history
  • Loading branch information
iBug committed Jan 23, 2024
1 parent ccadbe0 commit 688d325
Showing 1 changed file with 6 additions and 5 deletions.
11 changes: 6 additions & 5 deletions .github/workflows/build.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -37,11 +37,12 @@ jobs:
if: github.ref == 'refs/heads/master'
id: file_changes
run: |
if [[ -z $(git diff --name-only) ]]; then
echo "::set-output name=should_submit::false"
else
echo "::set-output name=should_submit::true"
fi
git add -A
if git diff-index --quiet --cached HEAD --; then
echo "should_submit=false" >> "$GITHUB_OUTPUT"
else
echo "should_submit=true" >> "$GITHUB_OUTPUT"
fi
- name: Submit PR if mdl changes files
if: steps.file_changes.outputs.should_submit == 'true' && github.ref == 'refs/heads/master'
Expand Down

0 comments on commit 688d325

Please sign in to comment.