aboutsummaryrefslogtreecommitdiffhomepage
path: root/scripts/build
diff options
context:
space:
mode:
Diffstat (limited to 'scripts/build')
-rwxr-xr-xscripts/build/client.sh23
1 files changed, 13 insertions, 10 deletions
diff --git a/scripts/build/client.sh b/scripts/build/client.sh
index 106532c4f..e4d053e82 100755
--- a/scripts/build/client.sh
+++ b/scripts/build/client.sh
@@ -10,16 +10,19 @@ defaultLanguage="en_US"
10npm run ng build -- --output-path "dist/$defaultLanguage/" --deploy-url "/client/$defaultLanguage/" --prod --stats-json 10npm run ng build -- --output-path "dist/$defaultLanguage/" --deploy-url "/client/$defaultLanguage/" --prod --stats-json
11mv "./dist/$defaultLanguage/assets" "./dist" 11mv "./dist/$defaultLanguage/assets" "./dist"
12 12
13# Supported languages 13# Don't build other languages if --light arg is provided
14languages=("fr_FR" "eu_ES" "ca_ES" "cs_CZ" "eo") 14if [ -z ${1+x} ] || [ "$1" != "--light" ]; then
15 15 # Supported languages
16for lang in "${languages[@]}"; do 16 languages=("fr_FR" "eu_ES" "ca_ES" "cs_CZ" "eo")
17 npm run ng build -- --prod --i18n-file "./src/locale/target/angular_$lang.xml" --i18n-format xlf --i18n-locale "$lang" \ 17
18 --output-path "dist/$lang/" --deploy-url "/client/$lang/" 18 for lang in "${languages[@]}"; do
19 19 npm run ng build -- --prod --i18n-file "./src/locale/target/angular_$lang.xml" --i18n-format xlf --i18n-locale "$lang" \
20 # Do no duplicate assets 20 --output-path "dist/$lang/" --deploy-url "/client/$lang/"
21 rm -r "./dist/$lang/assets" 21
22done 22 # Do no duplicate assets
23 rm -r "./dist/$lang/assets"
24 done
25fi
23 26
24NODE_ENV=production npm run webpack -- --config webpack/webpack.video-embed.js --mode production --json > "./dist/embed-stats.json" 27NODE_ENV=production npm run webpack -- --config webpack/webpack.video-embed.js --mode production --json > "./dist/embed-stats.json"
25 28