Skip to content

Commit

Permalink
fix(ci): fix git diff for i18n-update-scheduled
Browse files Browse the repository at this point in the history
  • Loading branch information
zyf722 committed Oct 28, 2024
1 parent 7e9ec92 commit de6db6f
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions .github/workflows/i18n-update-scheduled.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,8 @@ jobs:
steps:
- name: Check out repository
uses: actions/checkout@v4
with:
fetch-depth: 0

- name: Switch to i18n branch
run: |
Expand Down Expand Up @@ -97,9 +99,9 @@ jobs:
- name: Check if has differences between ${{ env.BRANCH }} and ${{ github.event.repository.default_branch }}
id: check-diff
run: |
DIFF=$(git diff --name-only $BRANCH ${{ github.event.repository.default_branch }})
DIFF=$(git diff --name-only $BRANCH origin/${{ github.event.repository.default_branch }})
if [[ -z $DIFF ]]; then
echo "No differences between $BRANCH and ${{ github.event.repository.default_branch }}."
echo "No difference between $BRANCH and ${{ github.event.repository.default_branch }}."
echo "SKIP=true" >> $GITHUB_ENV
fi
Expand Down

0 comments on commit de6db6f

Please sign in to comment.