diff --git a/setup.sh b/setup.sh index 821ba5f..e3753aa 100755 --- a/setup.sh +++ b/setup.sh @@ -16,15 +16,17 @@ fi # Copy the translations to ~/.local/share/forgebuild FORGEBUILD_DATA=$HOME/.local/share/forgebuild -if [ ! -f $FORGEBUILD_DATA/i18n/en.json ]; then +if [ ! -d $FORGEBUILD_DATA ]; then if ! mkdir -p $FORGEBUILD_DATA; then echo "Failed to create folder $FORGEBUILD_DATA to store translations" exit 2 fi - if ! cp -r spec/i18n $FORGEBUILD_DATA; then - echo "Failed to copy translations to $FORGEBUILD_DATA" - exit 3 - fi +fi +if ! cp -r spec/i18n $FORGEBUILD_DATA; then + echo "Failed to copy translations to $FORGEBUILD_DATA" + exit 3 +else + echo "Successfully updated translations in $FORGEBUILD_DATA" fi I18N_FOLDER=$FORGEBUILD_DATA/i18n