diff --git a/.gitea/workflows/pull_request.yaml b/.gitea/workflows/pull_request.yaml index a3ba6a3..64df356 100644 --- a/.gitea/workflows/pull_request.yaml +++ b/.gitea/workflows/pull_request.yaml @@ -102,62 +102,6 @@ jobs: echo "All messages translated." - - generate_localizations: - runs-on: ubuntu-latest - steps: - - name: Checkout code - uses: actions/checkout@v4 - - # Required for Flutter action - - name: Install jq - run: | - apt-get update - apt-get install -y jq - - - name: Set up Flutter - uses: subosito/flutter-action@v2 - with: - channel: stable - flutter-version: 3.41.0 - - - name: Get dependencies - run: | - git config --global --add safe.directory /opt/hostedtoolcache/flutter/stable-3.41.0-x64 - flutter pub get - - - name: Generate localizations - run: flutter gen-l10n --no-use-deferred-loading - - - name: Check generated files - id: generate_localizations - run: | - if [ -n "$(git status --porcelain lib/l10n)" ]; then - echo "has_changes=true" >> "$GITHUB_OUTPUT" - else - echo "has_changes=false" >> "$GITHUB_OUTPUT" - fi - - - name: Commit generated localizations - if: steps.generate_localizations.outputs.has_changes == 'true' - env: - GITEA_TOKEN: ${{ secrets.BOT_TOKEN }} - BRANCH_NAME: ${{ gitea.head_ref }} - run: | - git fetch origin "$BRANCH_NAME" - git checkout "$BRANCH_NAME" - - if [ -n "$(git status --porcelain lib test)" ]; then - git config --global user.name "Gitea Actions [bot]" - git config --global user.email "actions@yannick-weigert.de" - git config pull.rebase false - git pull origin "$BRANCH_NAME" - git add lib/l10n - git commit -m "Generated localizations [skip ci]" - git push origin "HEAD:$BRANCH_NAME" - else - echo "No changes to commit" - fi diff --git a/.gitea/workflows/push.yaml b/.gitea/workflows/push.yaml index cfe987a..4721655 100644 --- a/.gitea/workflows/push.yaml +++ b/.gitea/workflows/push.yaml @@ -99,7 +99,6 @@ jobs: generate_licenses: runs-on: ubuntu-latest - needs: update_version steps: - name: Checkout code uses: actions/checkout@v4 @@ -144,9 +143,65 @@ jobs: echo "No changes to commit" fi + generate_localizations: + runs-on: ubuntu-latest + steps: + - name: Checkout code + uses: actions/checkout@v4 + + # Required for Flutter action + - name: Install jq + run: | + apt-get update + apt-get install -y jq + + - name: Set up Flutter + uses: subosito/flutter-action@v2 + with: + channel: stable + flutter-version: 3.41.0 + + - name: Get dependencies + run: | + git config --global --add safe.directory /opt/hostedtoolcache/flutter/stable-3.41.0-x64 + flutter pub get + + - name: Generate localizations + run: flutter gen-l10n --no-use-deferred-loading + + - name: Check for changes + id: generate_localizations + run: | + if [ -n "$(git status --porcelain lib/l10n)" ]; then + echo "has_changes=true" >> "$GITHUB_OUTPUT" + else + echo "has_changes=false" >> "$GITHUB_OUTPUT" + fi + + - name: Commit generated localizations + if: steps.generate_localizations.outputs.has_changes == 'true' + env: + GITEA_TOKEN: ${{ secrets.BOT_TOKEN }} + BRANCH_NAME: ${{ gitea.ref_name }} + run: | + git fetch origin "$BRANCH_NAME" + git checkout "$BRANCH_NAME" + + if [ -n "$(git status --porcelain lib test)" ]; then + git config --global user.name "Gitea Actions [bot]" + git config --global user.email "actions@yannick-weigert.de" + git config pull.rebase false + git pull origin "$BRANCH_NAME" + git add lib/l10n + git commit -m "Generated localizations [skip ci]" + git push origin "HEAD:$BRANCH_NAME" + else + echo "No changes to commit" + fi + format: runs-on: ubuntu-latest - needs: [update_version, generate_licenses] + needs: [update_version, generate_licenses, generate_localizations] steps: - name: Checkout code uses: actions/checkout@v4 diff --git a/lib/l10n/generated/app_localizations_de.dart b/lib/l10n/generated/app_localizations_de.dart index 7fdffac..ea8e1f2 100644 --- a/lib/l10n/generated/app_localizations_de.dart +++ b/lib/l10n/generated/app_localizations_de.dart @@ -1,6 +1,5 @@ // ignore: unused_import import 'package:intl/intl.dart' as intl; - import 'app_localizations.dart'; // ignore_for_file: type=lint @@ -42,6 +41,53 @@ class AppLocalizationsDe extends AppLocalizations { @override String get color => 'Farbe'; + @override + String get color_blue => 'Blau'; + + @override + String get color_green => 'Grün'; + + @override + String get color_orange => 'Orange'; + + @override + String get color_pink => 'Rosa'; + + @override + String get color_purple => 'Lila'; + + @override + String get color_red => 'Rot'; + + @override + String get color_teal => 'Türkis'; + + @override + String get color_yellow => 'Gelb'; + + @override + String could_not_add_player(Object playerName) { + return 'Spieler:in $playerName konnte nicht hinzugefügt werden'; + } + + @override + String get create_game => 'Spielvorlage erstellen'; + + @override + String get create_group => 'Gruppe erstellen'; + + @override + String get create_match => 'Spiel erstellen'; + + @override + String get create_new_group => 'Neue Gruppe erstellen'; + + @override + String get created_on => 'Erstellt am'; + + @override + String get create_new_match => 'Neues Spiel erstellen'; + @override String get data => 'Daten';