Skip to content

Commit

Permalink
improve detect changes step
Browse files Browse the repository at this point in the history
  • Loading branch information
tschaume committed Nov 2, 2022
1 parent a9da6be commit 185405e
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions .github/workflows/upgrade-dependencies.yml
Expand Up @@ -29,9 +29,14 @@ jobs:
pip-compile -q --upgrade --all-extras -o requirements/${{ matrix.os }}_py${{ matrix.python-version }}_extras.txt
- name: Detect changes
id: changes
run: echo "count=$(git diff-index --quiet HEAD)" >> $GITHUB_OUTPUT
run: |
git diff-index --quiet HEAD
echo "count=$?" >> $GITHUB_OUTPUT
test -z "$(git ls-files --exclude-standard --others)"
echo "files=$?" >> $GITHUB_OUTPUT
cat $GITHUB_OUTPUT
- name: commit & push changes
if: steps.changes.outputs.count > 0
if: steps.changes.outputs.count > 0 || steps.changes.outputs.files > 0
run: |
git config user.name github-actions
git config user.email github-actions@github.com
Expand Down

0 comments on commit 185405e

Please sign in to comment.