From 1d5bcbf423c446021f1cbffc2be5837dea4c9444 Mon Sep 17 00:00:00 2001 From: Doug Blank Date: Thu, 26 Aug 2010 13:15:09 +0000 Subject: [PATCH] Do not display missing locale dir if in english svn: r15818 --- src/TransUtils.py | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/src/TransUtils.py b/src/TransUtils.py index 310b78afb..0570fee92 100644 --- a/src/TransUtils.py +++ b/src/TransUtils.py @@ -54,8 +54,12 @@ elif os.path.exists( os.path.join(const.ROOT_DIR, "lang") ): elif os.path.exists(os.path.join(const.PREFIXDIR, "share/locale")): LOCALEDIR = os.path.join(const.PREFIXDIR, "share/locale") else: - print 'Locale dir does not exist at' + os.path.join(const.PREFIXDIR, "share/locale") - print 'Running ./configure --prefix=YourPrefixDir might fix the problem' + lang = os.environ.get('LANG', 'en') + if lang and lang[:2] == 'en': + pass # No need to display warning, we're in English + else: + print 'Locale dir does not exist at ' + os.path.join(const.PREFIXDIR, "share/locale") + print 'Running ./configure --prefix=YourPrefixDir might fix the problem' LOCALEDIR = None LOCALEDOMAIN = 'gramps'