aboutsummaryrefslogtreecommitdiffstats
path: root/testing/getting-things-gnome/dont-require-py3-gettext.patch
diff options
context:
space:
mode:
Diffstat (limited to 'testing/getting-things-gnome/dont-require-py3-gettext.patch')
-rw-r--r--testing/getting-things-gnome/dont-require-py3-gettext.patch37
1 files changed, 0 insertions, 37 deletions
diff --git a/testing/getting-things-gnome/dont-require-py3-gettext.patch b/testing/getting-things-gnome/dont-require-py3-gettext.patch
deleted file mode 100644
index c3a5a76db3f..00000000000
--- a/testing/getting-things-gnome/dont-require-py3-gettext.patch
+++ /dev/null
@@ -1,37 +0,0 @@
-Upstream: Pending, https://github.com/getting-things-gnome/gtg/pull/387
-From a03b68f636f21a92922aff9be2b3b728a4bcd52f Mon Sep 17 00:00:00 2001
-From: Rasmus Thomsen <oss@cogitri.dev>
-Date: Thu, 2 Jul 2020 09:27:37 +0200
-Subject: [PATCH] Gracefully handle locale.{bind,}textdomain not being
- available
-
-When python is built without gettext support these functions aren't
-available and as such GTG fails to start without this change.
----
- GTG/gtg.in | 13 +++++++++++--
- 1 file changed, 11 insertions(+), 2 deletions(-)
-
-diff --git a/GTG/gtg.in b/GTG/gtg.in
-index a4ea12df..ea310186 100755
---- a/GTG/gtg.in
-+++ b/GTG/gtg.in
-@@ -99,8 +99,17 @@ if __name__ == "__main__":
-
- # Set up UI i18n
- LOCALE_DIR = '@localedir@'
-- locale.bindtextdomain('gtg', LOCALE_DIR)
-- locale.textdomain('gtg')
-+
-+ try:
-+ locale.bindtextdomain('gtg', LOCALE_DIR)
-+ locale.textdomain('gtg')
-+ except AttributeError as e:
-+ # Python built without gettext support doesn't have bindtextdomain()
-+ # and textdomain(), so gracefully fail here.
-+ print(
-+ "Couldn't bind the translation domain. Some translations won't "
-+ "work.\n{}".format(e))
-+
- gettext.bindtextdomain('gtg', LOCALE_DIR)
- gettext.textdomain('gtg')
-