1
0
mirror of https://github.com/home-assistant/frontend.git synced 2025-12-24 20:55:49 +00:00

Minify translations downloaded from Lokalise (#611)

This commit is contained in:
Adam Mills
2017-11-11 15:33:47 -05:00
committed by GitHub
parent adac8e55d7
commit 508b5d6d77
44 changed files with 108 additions and 253 deletions

View File

@@ -21,11 +21,9 @@ fi
[ -z "${LOKALISE_TOKEN-}" ] && LOKALISE_TOKEN="$(<.lokalise_token)"
PROJECT_ID="3420425759f6d6d241f598.13594006"
LOCAL_DIR="$(pwd)/translations"
DOWNLOAD_FILE="${LOCAL_DIR}/Home_Assistant_-_Polymer_frontend-locale.zip"
LOCAL_DIR="$(pwd)/build-temp"
FILE_FORMAT=json
rm -f ${LOCAL_DIR}/*.json
mkdir -p ${LOCAL_DIR}
docker run \
@@ -37,6 +35,5 @@ docker run \
--type json \
--dest /opt/dest
# Extract and delete downloaded zip bundle
unzip -j "${DOWNLOAD_FILE}" locale/* -d "${LOCAL_DIR}"
rm -f "${DOWNLOAD_FILE}"
# Extract and and minify the downloaded translations
./node_modules/.bin/gulp translations-extract