Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(ci): run merge aftering pulling from Lokalise #647

Merged
merged 3 commits into from
Nov 3, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 10 additions & 2 deletions .github/workflows/i18n-update-scheduled.yml
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,6 @@ jobs:
git config pull.rebase false
git fetch origin $BRANCH:$BRANCH
git checkout $BRANCH
git pull origin develop
else
git checkout -b $BRANCH
fi
Expand Down Expand Up @@ -101,7 +100,16 @@ jobs:
echo "LAST_COMMIT_SHA_PULL=$(git log -n 1 --format="%H" -- src/livecodes/i18n/locales)" >> $GITHUB_ENV
- name: Push changes
run: git push origin $BRANCH
run: |
git pull origin ${{ github.event.repository.default_branch }} || {
echo "Failed to pull from ${{ github.event.repository.default_branch }}."
echo "Please manually pull the changes, solve potential conflicts, and re-run the workflow."
echo "::error title=Pull failed::Failed to pull from ${{ github.event.repository.default_branch }}."
exit 1
}
git push origin $BRANCH
- name: Check if has differences between ${{ env.BRANCH }} and ${{ github.event.repository.default_branch }}
id: check-diff
Expand Down