aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRasmus Thomsen <oss@cogitri.dev>2020-07-02 09:30:02 +0200
committerRasmus Thomsen <oss@cogitri.dev>2020-07-02 08:22:10 +0000
commit5e86ac5d4778f4fb9c74727834191830bdb3892b (patch)
tree26431c6d0b695f50a5975320307071c8fdece47e
parent692a20732e84f5c97fd8312b369d43fc43c7bfc5 (diff)
downloadaports-5e86ac5d4778f4fb9c74727834191830bdb3892b.tar.gz
aports-5e86ac5d4778f4fb9c74727834191830bdb3892b.tar.bz2
aports-5e86ac5d4778f4fb9c74727834191830bdb3892b.tar.xz
testing/getting-things-gnome: upgrade to 20200622
-rw-r--r--testing/getting-things-gnome/APKBUILD8
-rw-r--r--testing/getting-things-gnome/dont-require-py3-gettext.patch50
2 files changed, 39 insertions, 19 deletions
diff --git a/testing/getting-things-gnome/APKBUILD b/testing/getting-things-gnome/APKBUILD
index 484d81cdbf..13fb125afc 100644
--- a/testing/getting-things-gnome/APKBUILD
+++ b/testing/getting-things-gnome/APKBUILD
@@ -1,8 +1,8 @@
# Contributor: Rasmus Thomsen <oss@cogitri.dev>
# Maintainer: Rasmus Thomsen <oss@cogitri.dev>
pkgname=getting-things-gnome
-_commit=2143d904f2e7076099f477540348bc6552817f20
-pkgver=20200521
+_commit=75ac270d0322fd33e3e926ad847009adc13ac1b5
+pkgver=20200622
pkgrel=0
pkgdesc="A personal tasks and TODO-list items organizier for GNOME, inspired by the Getting Things Done methodology"
url="https://wiki.gnome.org/Apps/GTG"
@@ -35,5 +35,5 @@ package() {
DESTDIR="$pkgdir" ninja -C output install
}
-sha512sums="e030d610de8307afe64cdaadef2d8ff79bf2d06bd3042d9aa0b79203421df01ac511737c654d87f56efc6b144971f72c440c31325fa9f2de98019cd54e3750af getting-things-gnome-20200521.tar.gz
-33eb3623839c6de450915cf6886ddf9301b2f9823ea634a1083bfd83388f01c7093999d0eeff842b6b20e5713e980ddcb5450fbd272876764424e578fccdb687 dont-require-py3-gettext.patch"
+sha512sums="012f58689e6dfe5b411ff13cec594ae9c6e19eeef27464d482a4dd839f97511fed883d0708c4a58be248056dcd424488a43f58edf637edad9905b3d609fa2c9f getting-things-gnome-20200622.tar.gz
+71ebc9626cc3545774cab5e6b5147d67456c40219cab8eb29b9c05640b6eb847ce58b3a4b2ad49c8da9a2ea547426d33546eafe2f2a54776fc94a6600868a45d dont-require-py3-gettext.patch"
diff --git a/testing/getting-things-gnome/dont-require-py3-gettext.patch b/testing/getting-things-gnome/dont-require-py3-gettext.patch
index 6041faaf2b..c3a5a76db3 100644
--- a/testing/getting-things-gnome/dont-require-py3-gettext.patch
+++ b/testing/getting-things-gnome/dont-require-py3-gettext.patch
@@ -1,17 +1,37 @@
-Upstream: No
-Reason: We build py3 without gettext support, so these functions dont
-exist
-diff --git a/GTG/core/translations.py b/GTG/core/translations.py
-index 6ff63a7..866e1be 100644
---- a/GTG/core/translations.py
-+++ b/GTG/core/translations.py
-@@ -30,9 +30,7 @@ GETTEXT_DOMAIN = 'gtg'
- LOCALE_PATH = gettext.bindtextdomain(GETTEXT_DOMAIN)
+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__":
- gettext.bindtextdomain(GETTEXT_DOMAIN, LOCALE_PATH)
--locale.bindtextdomain(GETTEXT_DOMAIN, LOCALE_PATH)
- gettext.textdomain(GETTEXT_DOMAIN)
--locale.textdomain(GETTEXT_DOMAIN)
-
- translation = gettext.translation(GETTEXT_DOMAIN, LOCALE_PATH, fallback=True)
+ # 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')