update versions to 2.4.0 #858
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Translations | |
on: | |
# Trigger the workflow only on master | |
push: | |
branches: | |
- master | |
jobs: | |
check_translation_files: | |
if: ( github.repository == 'MerginMaps/input' ) && (!contains(github.event.head_commit.message, 'Translate ')) | |
runs-on: ubuntu-latest | |
env: | |
QT_VERSION: '6.5.2' | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Install Qt | |
uses: jurplel/install-qt-action@v3 | |
with: | |
version: ${{ env.QT_VERSION }} | |
setup-python: 'false' | |
modules: 'qtsensors qtconnectivity qt5compat qtmultimedia qtpositioning qtshadertools' | |
dir: ${{ github.workspace }} | |
cache: true | |
cache-key-prefix: ${{ runner.os }}-QtCache-v0-${{ env.QT_VERSION }}-lnx | |
- name: Check for new translation entries | |
run: | | |
./scripts/update_i18n_ts.bash ${{ github.workspace }}/Qt/${{ env.QT_VERSION }}/gcc_64 | |
echo "Changes in i18n entries" | |
git diff app/i18n/input_en.ts | grep -E \\+\\\s+\<source\> || true | |
NCHANGES=`git diff app/i18n/input_en.ts | grep -E \\+\\\s+\<source\> | wc -l` | |
echo "Number of changes $NCHANGES" | |
if [ "$NCHANGES" -gt "0" ]; then | |
echo "Run ./scripts/update_i18n_ts.bash to fix" | |
echo "Step ./scripts/release_i18n_qm.bash skipped do to this error" | |
exit 1 | |
fi | |
- name: Check if qm files are up-to-date | |
run: | | |
./scripts/release_i18n_qm.bash | |
echo "Unreleased translations (translated but not released)" | |
git diff --name-only -- ':!*input_i18n.qrc' || true | |
echo "Number of changes" | |
NCHANGES=`git diff --name-only -- ':!*input_i18n.qrc' | wc -l` | |
echo "Number of changes $NCHANGES" | |
if [ "$NCHANGES" -gt "0" ]; then | |
echo "Run ./scripts/release_i18n_qm.bash to fix" | |
exit 1 | |
fi | |
- name: Info.plist translations check | |
run: | | |
./scripts/check_ios_translations.py ./cmake_templates/iOSInfo.plist.in ./app/i18n/input_i18n.qrc | |
if [ $? -gt "0" ]; then | |
echo "Info.plist does not include the same translations as input_i18n.qrc, exit.." | |
exit 1 | |
fi |