mirror of
https://github.com/yu-i-i/overleaf-cep.git
synced 2026-11-15 14:43:46 +01:00
25 lines
505 B
Bash
Executable File
25 lines
505 B
Bash
Executable File
#!/bin/bash
|
|
|
|
set -e
|
|
|
|
# Ensure all locales used in the frontend are tracked
|
|
OUTPUT=data/dumpFolder/i18next-scanner
|
|
trap 'rm -rf "$OUTPUT"' EXIT
|
|
yarn exec i18next-scanner --output "$OUTPUT"
|
|
ACTUAL=frontend/extracted-translations.json
|
|
EXPECTED="$OUTPUT/frontend/extracted-translations.json"
|
|
if ! diff "$ACTUAL" "$EXPECTED"; then
|
|
cat <<MSG >&2
|
|
|
|
services/web/frontend/extracted-translations.json is not up-to-date.
|
|
|
|
---
|
|
Try running:
|
|
|
|
internal$ bin/run web npm run extract-translations
|
|
|
|
---
|
|
MSG
|
|
exit 1
|
|
fi
|