This commit is contained in:
Félix Malfait
2025-02-19 09:24:01 +01:00
committed by GitHub
parent df3d3a3c0c
commit 248ec4cd6f
2 changed files with 14 additions and 4 deletions

View File

@ -94,6 +94,7 @@ jobs:
- name: Commit Translations - name: Commit Translations
run: | run: |
git config --global --add safe.directory "$GITHUB_WORKSPACE"
git config --global user.name 'github-actions' git config --global user.name 'github-actions'
git config --global user.email 'github-actions@twenty.com' git config --global user.email 'github-actions@twenty.com'
git add . git add .
@ -125,6 +126,11 @@ jobs:
- name: Create pull request - name: Create pull request
if: steps.check_changes.outputs.changes_detected == 'true' if: steps.check_changes.outputs.changes_detected == 'true'
run: gh pr create -B main -H i18n --title 'i18n - translations' --body 'Created by Github action' || true run: |
if git diff --name-only origin/main..HEAD | grep -q .; then
gh pr create -B main -H i18n --title 'i18n - translations' --body 'Created by Github action' || true
else
echo "No file differences between branches, skipping PR creation"
fi
env: env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

View File

@ -91,9 +91,13 @@ jobs:
# Visit https://crowdin.com/settings#api-key to create this token # Visit https://crowdin.com/settings#api-key to create this token
CROWDIN_PERSONAL_TOKEN: ${{ secrets.CROWDIN_PERSONAL_TOKEN }} CROWDIN_PERSONAL_TOKEN: ${{ secrets.CROWDIN_PERSONAL_TOKEN }}
- name: Create a pull request - name: Create a pull request
if: steps.check_extract_changes.outputs.changes_detected == 'true' || steps.check_compile_changes.outputs.changes_detected == 'true' if: steps.check_extract_changes.outputs.changes_detected == 'true' || steps.check_compile_changes.outputs.changes_detected == 'true'
run: gh pr create -B main -H i18n --title 'i18n - translations' --body 'Created by Github action' || true run: |
if git diff --name-only origin/main..HEAD | grep -q .; then
gh pr create -B main -H i18n --title 'i18n - translations' --body 'Created by Github action' || true
else
echo "No file differences between branches, skipping PR creation"
fi
env: env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}