Browse Source

Fix findMissingTranslations.sh for 2.0.x

Scott Lahteine 6 years ago
parent
commit
13940268a2
1 changed files with 7 additions and 2 deletions
  1. 7
    2
      buildroot/share/scripts/findMissingTranslations.sh

+ 7
- 2
buildroot/share/scripts/findMissingTranslations.sh View File

9
 # If no language codes are specified then all languages will be checked
9
 # If no language codes are specified then all languages will be checked
10
 #
10
 #
11
 
11
 
12
-[ -d "Marlin" ] && cd "Marlin"
12
+LANGHOME="Marlin/src/lcd/language"
13
+
14
+[ -d $LANGHOME ] && cd $LANGHOME
13
 
15
 
14
 FILES=$(ls language_*.h | grep -v -E "(_en|_test)\.h" | sed -E 's/language_([^\.]+)\.h/\1/')
16
 FILES=$(ls language_*.h | grep -v -E "(_en|_test)\.h" | sed -E 's/language_([^\.]+)\.h/\1/')
15
 declare -A STRING_MAP
17
 declare -A STRING_MAP
40
 echo
42
 echo
41
 
43
 
42
 for K in $( printf "%s\n" "${!STRING_MAP[@]}" | sort ); do
44
 for K in $( printf "%s\n" "${!STRING_MAP[@]}" | sort ); do
43
-  printf "%-35s :%s\n" "$K" "${STRING_MAP[$K]}"
45
+  case "$#" in
46
+    1 ) echo $K ;;
47
+    * ) printf "%-35s :%s\n" "$K" "${STRING_MAP[$K]}" ;;
48
+  esac
44
 done
49
 done

Loading…
Cancel
Save