commit: 1ddf70fde01795a6b4ee92321f553fd9dab7ba92 Author: Andreas Sturmlechner <asturm <AT> gentoo <DOT> org> AuthorDate: Thu Jan 14 19:20:33 2021 +0000 Commit: Andreas Sturmlechner <asturm <AT> gentoo <DOT> org> CommitDate: Thu Jan 14 19:48:48 2021 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=1ddf70fd
kde-apps/libkgapi: Remember GMail auth token See also: https://bugs.kde.org/show_bug.cgi?id=429406 Package-Manager: Portage-3.0.13, Repoman-3.0.2 Signed-off-by: Andreas Sturmlechner <asturm <AT> gentoo.org> ...ibkgapi-20.12.1-remember-gmail-auth-token.patch | 30 +++++++++++++++++++ kde-apps/libkgapi/libkgapi-20.12.1-r1.ebuild | 35 ++++++++++++++++++++++ 2 files changed, 65 insertions(+) diff --git a/kde-apps/libkgapi/files/libkgapi-20.12.1-remember-gmail-auth-token.patch b/kde-apps/libkgapi/files/libkgapi-20.12.1-remember-gmail-auth-token.patch new file mode 100644 index 00000000000..4d777f1475f --- /dev/null +++ b/kde-apps/libkgapi/files/libkgapi-20.12.1-remember-gmail-auth-token.patch @@ -0,0 +1,30 @@ +From d81d247026ac993ac5717ca471c7fcf1778951f2 Mon Sep 17 00:00:00 2001 +From: Antonio Rojas <[email protected]> +Date: Wed, 6 Jan 2021 15:54:52 +0100 +Subject: [PATCH] Don't reset account scopes if not necessary + +This triggers unnecesary authentication prompts + +BUG: 429406 +--- + src/core/accountmanager.cpp | 4 +++- + 1 file changed, 3 insertions(+), 1 deletion(-) + +diff --git a/src/core/accountmanager.cpp b/src/core/accountmanager.cpp +index b9af6c1..f68563e 100644 +--- a/src/core/accountmanager.cpp ++++ b/src/core/accountmanager.cpp +@@ -81,7 +81,9 @@ public: + currentScopes.push_back(requestedScope); + } + } +- account->setScopes(currentScopes); ++ if (currentScopes != account->scopes()) { ++ account->setScopes(currentScopes); ++ } + } + auto *job = new AuthJob(account, apiKey, apiSecret); + job->setUsername(account->accountName()); +-- +GitLab + diff --git a/kde-apps/libkgapi/libkgapi-20.12.1-r1.ebuild b/kde-apps/libkgapi/libkgapi-20.12.1-r1.ebuild new file mode 100644 index 00000000000..07016b6b5f8 --- /dev/null +++ b/kde-apps/libkgapi/libkgapi-20.12.1-r1.ebuild @@ -0,0 +1,35 @@ +# Copyright 1999-2021 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 + +ECM_TEST="true" +KFMIN=5.75.0 +QTMIN=5.15.1 +VIRTUALX_REQUIRED="test" +inherit ecm kde.org + +DESCRIPTION="Library for accessing Google calendar and contact resources" +HOMEPAGE="https://api.kde.org/kdepim/libkgapi/html/index.html" + +LICENSE="LGPL-2.1+" +SLOT="5" +KEYWORDS="~amd64 ~arm64 ~ppc64 ~x86" +IUSE="nls" + +BDEPEND=" + nls? ( >=dev-qt/linguist-tools-${QTMIN}:5 ) +" +DEPEND=" + dev-libs/cyrus-sasl:2 + >=dev-qt/qtgui-${QTMIN}:5 + >=dev-qt/qtnetwork-${QTMIN}:5 + >=dev-qt/qtwidgets-${QTMIN}:5 + >=dev-qt/qtxml-${QTMIN}:5 + >=kde-frameworks/kcalendarcore-${KFMIN}:5 + >=kde-frameworks/kcontacts-${KFMIN}:5 + >=kde-frameworks/kwallet-${KFMIN}:5 +" +RDEPEND="${DEPEND}" + +PATCHES=( "${FILESDIR}/${P}-remember-gmail-auth-token.patch" ) # KDE-Bug 429406
