Pārlūkot izejas kodu

Improve grep match for hst_scan_i18n.sh

myrevery 4 gadi atpakaļ
vecāks
revīzija
8b7a7618b3
1 mainītis faili ar 1 papildinājumiem un 1 dzēšanām
  1. 1 1
      web/locale/hst_scan_i18n.sh

+ 1 - 1
web/locale/hst_scan_i18n.sh

@@ -15,7 +15,7 @@ find ../.. \( -name '*.php' -o -name '*.html' -o -name '*.sh' \) | xgettext --ou
 OLDIFS=$IFS
 OLDIFS=$IFS
 IFS=$'\n'
 IFS=$'\n'
 for string in $(awk -F'SYSTEM=' '/data=".+ SYSTEM=[^"]/ {print $2}' $HESTIA/bin/v-list-sys-services | cut -d\' -f2); do
 for string in $(awk -F'SYSTEM=' '/data=".+ SYSTEM=[^"]/ {print $2}' $HESTIA/bin/v-list-sys-services | cut -d\' -f2); do
-    if [ -z "$(grep "$string" hestiacp.pot)" ]; then
+    if [ -z "$(grep "\"$string\"" hestiacp.pot)" ]; then
         echo -e "\n#: ../../bin/v-list-sys-services:"$(grep -n "$string" $HESTIA/bin/v-list-sys-services | cut -d: -f1)"\nmsgid \"$string\"\nmsgstr \"\"" >> hestiacp.pot
         echo -e "\n#: ../../bin/v-list-sys-services:"$(grep -n "$string" $HESTIA/bin/v-list-sys-services | cut -d: -f1)"\nmsgid \"$string\"\nmsgstr \"\"" >> hestiacp.pot
     fi
     fi
 done
 done