Revision control

1
#!/bin/bash
2
3
if [ -d l10n-screenshots ]; then
4
echo "The l10n-screenshots directory already exists. You decide."
5
exit 1
6
fi
7
8
if [ ! -d firefoxios-l10n ]; then
9
echo "Did not find a firefox-ios-l10n checkout. Are you running this on a localized build?"
10
exit 1
11
fi
12
13
mkdir l10n-screenshots
14
15
LOCALES=$*
16
if [ $# -eq 0 ]; then
17
LOCALES="af ar ast az bg bn br bs ca cs cy da de dsb el en-GB en-US eo es es-CL es-MX eu fa fr ga-IE gd gl he hi-IN hsb hu hy-AM id is it ja kab kk km kn ko lo lt lv ml ms my nb-NO ne-NP nl nn-NO or pa-IN pl pt-BR pt-PT rm ro ru ses si sk sl sq sv-SE te th tl tn tr uk ur uz zh-CN zh-TW"
18
fi
19
20
for lang in $LOCALES; do
21
echo "$(date) Snapshotting $lang"
22
mkdir "l10n-screenshots/$lang"
23
fastlane snapshot --project Client.xcodeproj --scheme L10nSnapshotTests \
24
--skip_open_summary \
25
--derived_data_path l10n-screenshots-dd \
26
--erase_simulator --localize_simulator \
27
--devices "iPhone SE" --languages "$lang" \
28
--output_directory "l10n-screenshots/$lang" > "l10n-screenshots/$lang/snapshot.log" 2>&1
29
done