From d421d4815631baaeb5d1f726b50c7d9e9a19c1c3 Mon Sep 17 00:00:00 2001 From: Alain Reguera Delgado Date: Jul 18 2011 01:43:03 +0000 Subject: Update `locale' functionality: - Fix pattern used to update metadata inside portable object files to make the `Report-Msgid-Bugs-To:' field to expand as expected. --- diff --git a/Scripts/Functions/Locale/locale_updateMessageMetadata.sh b/Scripts/Functions/Locale/locale_updateMessageMetadata.sh index 567d3ce..6d402e3 100755 --- a/Scripts/Functions/Locale/locale_updateMessageMetadata.sh +++ b/Scripts/Functions/Locale/locale_updateMessageMetadata.sh @@ -45,10 +45,10 @@ function locale_updateMessageMetadata { # Define pattern lines. The pattern lines are put inside portable # objects through xgettext and xml2po commands . - SRC[0]='Project-Id-Version:' - SRC[1]='Report-Msgid-Bugs-To:' - SRC[2]='Last-Translator:' - SRC[3]='Language-Team:' + SRC[0]="\"Project-Id-Version:" + SRC[1]="\"Report-Msgid-Bugs-To:" + SRC[2]="\"Last-Translator:" + SRC[3]="\"Language-Team:" # Define replacement lines for pattern line. DST[0]="\"Project-Id-Version: ${CLI_PROGRAM} (${CURRENTLOCALE})\\\n\"" diff --git a/Scripts/Functions/Locale/locale_updateMessageShell.sh b/Scripts/Functions/Locale/locale_updateMessageShell.sh index 014b7ae..88d78f4 100755 --- a/Scripts/Functions/Locale/locale_updateMessageShell.sh +++ b/Scripts/Functions/Locale/locale_updateMessageShell.sh @@ -56,6 +56,9 @@ function locale_updateMessageShell { --copyright-holder="The CentOS L10n SIG" \ --width=70 --sort-by-file ${FILES} + # Sanitate portable object template metadata. + ${FUNCNAM}_updateMessageMetadata "${FILE}.pot" + # Verify, initialize or update portable objects from portable # object templates. ${FUNCNAM}_updateMessagePObjects "${FILE}"