From 3fa79c0fa5619911e7a251e2b3a837fdaa426f48 Mon Sep 17 00:00:00 2001 From: Caolán McNamara Date: Mon, 11 Sep 2017 10:44:06 +0100 Subject: disallow .ui translatable entries without context at checkin MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Change-Id: Iece6ae3c4eabad4cd113f469495d2c42833a7b92 Reviewed-on: https://gerrit.libreoffice.org/42157 Tested-by: Jenkins Reviewed-by: Caolán McNamara Tested-by: Caolán McNamara --- .git-hooks/pre-commit | 5 +++++ 1 file changed, 5 insertions(+) (limited to '.git-hooks') diff --git a/.git-hooks/pre-commit b/.git-hooks/pre-commit index 4a21655e8cfe..07569905488b 100755 --- a/.git-hooks/pre-commit +++ b/.git-hooks/pre-commit @@ -92,6 +92,11 @@ sub check_whitespaces($) { bad_line("use tooltip_text instead of tooltip_markup", $_, $src_limited); } + if ((/translatable="yes"/) and not(/context=/)) + { + bad_line("translatable .ui file line without context", $_, $src_limited); + } + } } if ( $found_bad) -- cgit