[PATCH v2][Wok] Improve UI error codes checking

Signed-off-by: Ramon Medeiros <ramonn@linux.vnet.ibm.com> --- Changes: v2: Use "+" instead of "*". This expression only match WOKXXXXXX, and no more WOK, what was causing trouble before check_ui_code_errors.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/check_ui_code_errors.sh b/check_ui_code_errors.sh index 4d9a8bd..6b7ea7e 100755 --- a/check_ui_code_errors.sh +++ b/check_ui_code_errors.sh @@ -20,7 +20,7 @@ # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA errors="$(cat ui/pages/i18n.json.tmpl | grep -o 'WOK[0-9A-Z]*'| sort)" -uiErrors="$(grep -Ro 'WOK[0-9A-Z]*' ui/js/ | cut -d: -f2 | sort| uniq)" +uiErrors="$(grep -ERo 'WOK[0-9A-Z]+' ui/js/ | cut -d: -f2 | sort| uniq)" # all errors on i18n are present in js/html files: success if [ "$errors" == "$uiErrors" ]; then -- 2.5.5

Reviewed-By: Lucio Correia <luciojhc@linux.vnet.ibm.com> On 10-06-2016 12:46, Ramon Medeiros wrote:
Signed-off-by: Ramon Medeiros <ramonn@linux.vnet.ibm.com> --- Changes:
v2: Use "+" instead of "*". This expression only match WOKXXXXXX, and no more WOK, what was causing trouble before
check_ui_code_errors.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/check_ui_code_errors.sh b/check_ui_code_errors.sh index 4d9a8bd..6b7ea7e 100755 --- a/check_ui_code_errors.sh +++ b/check_ui_code_errors.sh @@ -20,7 +20,7 @@ # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
errors="$(cat ui/pages/i18n.json.tmpl | grep -o 'WOK[0-9A-Z]*'| sort)" -uiErrors="$(grep -Ro 'WOK[0-9A-Z]*' ui/js/ | cut -d: -f2 | sort| uniq)" +uiErrors="$(grep -ERo 'WOK[0-9A-Z]+' ui/js/ | cut -d: -f2 | sort| uniq)"
# all errors on i18n are present in js/html files: success if [ "$errors" == "$uiErrors" ]; then
-- Lucio Correia Software Engineer IBM LTC Brazil

Hi Ramon, please, next time, give a deep explanation on the problem/improvement you are trying to solve with your patch. Regards, Aline Manera On 06/10/2016 12:46 PM, Ramon Medeiros wrote:
Signed-off-by: Ramon Medeiros <ramonn@linux.vnet.ibm.com> --- Changes:
v2: Use "+" instead of "*". This expression only match WOKXXXXXX, and no more WOK, what was causing trouble before
check_ui_code_errors.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/check_ui_code_errors.sh b/check_ui_code_errors.sh index 4d9a8bd..6b7ea7e 100755 --- a/check_ui_code_errors.sh +++ b/check_ui_code_errors.sh @@ -20,7 +20,7 @@ # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
errors="$(cat ui/pages/i18n.json.tmpl | grep -o 'WOK[0-9A-Z]*'| sort)" -uiErrors="$(grep -Ro 'WOK[0-9A-Z]*' ui/js/ | cut -d: -f2 | sort| uniq)" +uiErrors="$(grep -ERo 'WOK[0-9A-Z]+' ui/js/ | cut -d: -f2 | sort| uniq)"
# all errors on i18n are present in js/html files: success if [ "$errors" == "$uiErrors" ]; then
participants (3)
-
Aline Manera
-
Lucio Correia
-
Ramon Medeiros