diff options
author | Chocobozzz <me@florianbigard.com> | 2018-07-18 09:52:46 +0200 |
---|---|---|
committer | Chocobozzz <me@florianbigard.com> | 2018-07-18 10:00:37 +0200 |
commit | e032aec9b92be25a996923361f83a96a89505254 (patch) | |
tree | 245b559061fdcb1c27946333ff7ecd6bd82247f7 /scripts/build | |
parent | 1d94c154689b89b2c5e55f6e12ec25f49b369d52 (diff) | |
download | PeerTube-e032aec9b92be25a996923361f83a96a89505254.tar.gz PeerTube-e032aec9b92be25a996923361f83a96a89505254.tar.zst PeerTube-e032aec9b92be25a996923361f83a96a89505254.zip |
Render CSS/title/description tags on server side
Diffstat (limited to 'scripts/build')
-rwxr-xr-x | scripts/build/client.sh | 23 |
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" | |||
10 | npm run ng build -- --output-path "dist/$defaultLanguage/" --deploy-url "/client/$defaultLanguage/" --prod --stats-json | 10 | npm run ng build -- --output-path "dist/$defaultLanguage/" --deploy-url "/client/$defaultLanguage/" --prod --stats-json |
11 | mv "./dist/$defaultLanguage/assets" "./dist" | 11 | mv "./dist/$defaultLanguage/assets" "./dist" |
12 | 12 | ||
13 | # Supported languages | 13 | # Don't build other languages if --light arg is provided |
14 | languages=("fr_FR" "eu_ES" "ca_ES" "cs_CZ" "eo") | 14 | if [ -z ${1+x} ] || [ "$1" != "--light" ]; then |
15 | 15 | # Supported languages | |
16 | for 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 | |
22 | done | 22 | # Do no duplicate assets |
23 | rm -r "./dist/$lang/assets" | ||
24 | done | ||
25 | fi | ||
23 | 26 | ||
24 | NODE_ENV=production npm run webpack -- --config webpack/webpack.video-embed.js --mode production --json > "./dist/embed-stats.json" | 27 | NODE_ENV=production npm run webpack -- --config webpack/webpack.video-embed.js --mode production --json > "./dist/embed-stats.json" |
25 | 28 | ||