Files
game-tracker/.gitea/workflows/pull_request.yaml
Felix Kirchner 5f031ddd51
Some checks failed
Pull Request Pipeline / lint (pull_request) Failing after 2s
Pull Request Pipeline / localizations (pull_request) Successful in 27s
Pull Request Pipeline / test (pull_request) Successful in 1m30s
tried lint
2026-05-25 13:56:50 +02:00

83 lines
1.9 KiB
YAML

name: Pull Request Pipeline
on:
pull_request:
jobs:
lint:
runs-on: ubuntu-latest
container:
image: ghcr.io/cirruslabs/flutter:stable
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Get dependencies
run: |
git config --global --add safe.directory '*'
flutter pub get
- name: Analyze Formatting
run: flutter analyze lib test
test:
runs-on: ubuntu-latest
container:
image: ghcr.io/cirruslabs/flutter:stable
steps:
- name: Install Node
run: |
apt-get update
apt-get install -y nodejs npm
- name: Checkout code
uses: actions/checkout@v4
- name: Get dependencies
run: |
git config --global --add safe.directory '*'
flutter pub get
- name: Run tests
run: flutter test
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
- name: Get dependencies
run: |
git config --global --add safe.directory '*'
flutter pub get
- name: Check for untranslated messages
run: |
flutter gen-l10n --no-use-deferred-loading
UNTRANSLATED_FILE=lib/l10n/untranslated_messages.json
if [ ! -f "$UNTRANSLATED_FILE" ]; then
echo "Expected $UNTRANSLATED_FILE to be generated, but it does not exist."
exit 1
fi
CONTENT=$(tr -d '[:space:]' < "$UNTRANSLATED_FILE")
if [ "$CONTENT" != "{}" ]; then
echo "Found untranslated messages:"
cat "$UNTRANSLATED_FILE"
exit 1
fi
echo "All messages translated."