Skip to content
This repository has been archived by the owner on Sep 26, 2024. It is now read-only.

Commit

Permalink
chore: clean up workflow and added PR desc template (#5895)
Browse files Browse the repository at this point in the history
  • Loading branch information
prince-deriv authored Nov 10, 2023
1 parent 63f8706 commit 9de669e
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 3 deletions.
9 changes: 9 additions & 0 deletions .github/translation_sync_template.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
## πŸ€– Automated Translation Pull Request
This is an automated pull request to fetch the newly translated strings from `Crowdin` to ensure
that we do not overwrite the translations provided by the translation team before pushing our new strings.

## πŸ“ Note:
- It is recommended to merge this PR immediately to minimize the risk of conflicts, although the likelihood of conflicts is very low.
- In the event of a missed merge and another PR is merged into the master branch, this PR will be automatically deleted, and a new one with the latest updates will be created.
- Prior to creating this PR, the translations from the master branch and Crowdin are synchronized and sent to Crowdin for the latest updates.
- This PR is essential for updating our codebase with the synchronized version sent to Crowdin, ensuring that both platforms have the same working copy.
5 changes: 2 additions & 3 deletions .github/workflows/translation-sync.yml
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,6 @@ jobs:
# Commit the newly downloaded files
cd $(git rev-parse --show-toplevel)
echo "GIT STATUS: $(git status --porcelain)"
git add .
git commit -m "translations: πŸ“š sync translations with crowdin"
Expand All @@ -61,7 +60,7 @@ jobs:
sudo apt install gh
gh auth login --with-token <<< ${{ github.token }}
gh pr close "$branch_name" || true
gh pr create --base "master" --title "[Translations] New strings from crowdin πŸ“š" --head "binary-com:$branch_name" --body "This is an automated pull request to fetch the newly translated strings from Crowdin to ensure that we do not overwrite the translations provided by the translation team before pushing our new strings."
gh pr create --base "master" --title "[translations] New strings from crowdin πŸ“š" --head "binary-com:$branch_name" -F ".github/translation_sync_template.md"
fi
# Upload new strings to Crowdin
Expand All @@ -75,7 +74,7 @@ jobs:
{
attachments: [{
color: '${{ job.status }}' === 'success' ? 'good' : '${{ job.status }}' === 'failure' ? 'danger' : 'warning',
text: `*[Deriv.com]* New strings are pushed to crowdin master branch:(https://crowdin.com/project/deriv-com/content/files)`
text: `*[Deriv.com]* strings are synced to crowdin master branch:(https://crowdin.com/project/deriv-com/content/files)`
}]
}
env:
Expand Down

1 comment on commit 9de669e

@vercel
Copy link

@vercel vercel bot commented on 9de669e Nov 10, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Successfully deployed to the following URLs:

deriv-com – ./

deriv-com.binary.sx
deriv-com-git-master.binary.sx

Please sign in to comment.