diff options
Diffstat (limited to 'scripts')
-rwxr-xr-x | scripts/build/client.sh | 2 | ||||
-rwxr-xr-x | scripts/i18n/create-custom-files.ts | 11 | ||||
-rwxr-xr-x | scripts/release.sh | 10 |
3 files changed, 16 insertions, 7 deletions
diff --git a/scripts/build/client.sh b/scripts/build/client.sh index 567a6e5e0..5b70b6045 100755 --- a/scripts/build/client.sh +++ b/scripts/build/client.sh | |||
@@ -31,7 +31,7 @@ post_build_hook | |||
31 | # Don't build other languages if --light arg is provided | 31 | # Don't build other languages if --light arg is provided |
32 | if [ -z ${1+x} ] || [ "$1" != "--light" ]; then | 32 | if [ -z ${1+x} ] || [ "$1" != "--light" ]; then |
33 | # Supported languages | 33 | # Supported languages |
34 | languages=("fr_FR" "eu_ES" "ca_ES" "cs_CZ" "eo") | 34 | languages=("fr_FR" "eu_ES" "ca_ES" "cs_CZ" "eo" "zh_Hant_TW" "de_DE" "es_ES") |
35 | 35 | ||
36 | for lang in "${languages[@]}"; do | 36 | for lang in "${languages[@]}"; do |
37 | # TODO: remove when the project will use runtime translations | 37 | # TODO: remove when the project will use runtime translations |
diff --git a/scripts/i18n/create-custom-files.ts b/scripts/i18n/create-custom-files.ts index a297fa79c..c4f8411e1 100755 --- a/scripts/i18n/create-custom-files.ts +++ b/scripts/i18n/create-custom-files.ts | |||
@@ -1,7 +1,14 @@ | |||
1 | import * as jsToXliff12 from 'xliff/jsToXliff12' | 1 | import * as jsToXliff12 from 'xliff/jsToXliff12' |
2 | import { writeFile } from 'fs' | 2 | import { writeFile } from 'fs' |
3 | import { join } from 'path' | 3 | import { join } from 'path' |
4 | import { buildLanguages, VIDEO_CATEGORIES, VIDEO_LICENCES, VIDEO_PRIVACIES } from '../../server/initializers/constants' | 4 | import { |
5 | buildLanguages, | ||
6 | VIDEO_CATEGORIES, | ||
7 | VIDEO_IMPORT_STATES, | ||
8 | VIDEO_LICENCES, | ||
9 | VIDEO_PRIVACIES, | ||
10 | VIDEO_STATES | ||
11 | } from '../../server/initializers/constants' | ||
5 | import { values } from 'lodash' | 12 | import { values } from 'lodash' |
6 | 13 | ||
7 | type TranslationType = { | 14 | type TranslationType = { |
@@ -33,6 +40,8 @@ const serverKeys: any = {} | |||
33 | values(VIDEO_CATEGORIES) | 40 | values(VIDEO_CATEGORIES) |
34 | .concat(values(VIDEO_LICENCES)) | 41 | .concat(values(VIDEO_LICENCES)) |
35 | .concat(values(VIDEO_PRIVACIES)) | 42 | .concat(values(VIDEO_PRIVACIES)) |
43 | .concat(values(VIDEO_STATES)) | ||
44 | .concat(values(VIDEO_IMPORT_STATES)) | ||
36 | .forEach(v => serverKeys[v] = v) | 45 | .forEach(v => serverKeys[v] = v) |
37 | 46 | ||
38 | // More keys | 47 | // More keys |
diff --git a/scripts/release.sh b/scripts/release.sh index b5fa68f42..4b45c959d 100755 --- a/scripts/release.sh +++ b/scripts/release.sh | |||
@@ -25,8 +25,8 @@ if [ -z "$GITHUB_TOKEN" ]; then | |||
25 | fi | 25 | fi |
26 | 26 | ||
27 | branch=$(git symbolic-ref --short -q HEAD) | 27 | branch=$(git symbolic-ref --short -q HEAD) |
28 | if [ "$branch" != "develop" ]; then | 28 | if [ "$branch" != "develop" ] && [[ "$branch" != feature/* ]]; then |
29 | echo "Need to be on develop branch." | 29 | echo "Need to be on develop or release branch." |
30 | exit -1 | 30 | exit -1 |
31 | fi | 31 | fi |
32 | 32 | ||
@@ -102,14 +102,14 @@ rm "./client/dist/embed-stats.json" | |||
102 | github-release upload --user chocobozzz --repo peertube --tag "$version" --name "$tar_name" --file "$tar_name" | 102 | github-release upload --user chocobozzz --repo peertube --tag "$version" --name "$tar_name" --file "$tar_name" |
103 | github-release upload --user chocobozzz --repo peertube --tag "$version" --name "$tar_name.asc" --file "$tar_name.asc" | 103 | github-release upload --user chocobozzz --repo peertube --tag "$version" --name "$tar_name.asc" --file "$tar_name.asc" |
104 | 104 | ||
105 | git push origin develop | 105 | git push origin "$branch" |
106 | 106 | ||
107 | # Only update master if it is not a pre release | 107 | # Only update master if it is not a pre release |
108 | if [ -z "$github_prerelease_option" ]; then | 108 | if [ -z "$github_prerelease_option" ]; then |
109 | # Update master branch | 109 | # Update master branch |
110 | git checkout master | 110 | git checkout master |
111 | git rebase develop | 111 | git merge "$branch" |
112 | git push origin master | 112 | git push origin master |
113 | git checkout develop | 113 | git checkout "$branch" |
114 | fi | 114 | fi |
115 | ) | 115 | ) |