From 87a3c923a61c22ff5de9ffa903650f0f160b390c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Cristian=20Cezar=20Mois=C3=A9s?= Date: Fri, 3 Jan 2025 23:08:30 +0000 Subject: [PATCH] Update update-en-US-packs.sh MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Cristian Cezar Moisés --- scripts/update-en-US-packs.sh | 26 +++++++++++++++++++++++++- 1 file changed, 25 insertions(+), 1 deletion(-) diff --git a/scripts/update-en-US-packs.sh b/scripts/update-en-US-packs.sh index 95931275..4e3065ac 100644 --- a/scripts/update-en-US-packs.sh +++ b/scripts/update-en-US-packs.sh @@ -1,2 +1,26 @@ +#!/bin/bash + +# Function to display usage +usage() { + echo "Usage: $0 " + echo "Example: $0 en-US" + exit 1 +} + +# Check if language code is provided +if [ -z "$1" ]; then + usage +fi + +LANGUAGE_CODE="$1" + +# Execute the copy-language-pack script and capture output +echo "Copying language pack for: $LANGUAGE_CODE" + +if sh ./scripts/copy-language-pack.sh "$LANGUAGE_CODE"; then + echo "Successfully copied language pack for: $LANGUAGE_CODE" +else + echo "Error: Failed to copy language pack for: $LANGUAGE_CODE" >&2 + exit 1 +fi -sh ./scripts/copy-language-pack.sh en-US