[X2Go-Commits] [x2go-keyring] 25/47: debian/postinst: sync with debian-archive-keyring package.

git-admin at x2go.org git-admin at x2go.org
Sun Aug 4 16:28:16 CEST 2019


This is an automated email from the git hooks/post-receive script.

x2go pushed a commit to branch master
in repository x2go-keyring.

commit 86b23ae68a930f0c57b558bbeb0f457838a9112d
Author: Mihai Moldovan <ionic at ionic.de>
Date:   Sun Aug 4 14:39:47 2019 +0200

    debian/postinst: sync with debian-archive-keyring package.
---
 debian/changelog |  2 ++
 debian/postinst  | 20 +++++++++++++++++---
 2 files changed, 19 insertions(+), 3 deletions(-)

diff --git a/debian/changelog b/debian/changelog
index 9607456..39ebe1f 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -55,6 +55,8 @@ x2go-keyring (2014.07.09) UNRELEASED; urgency=medium
   * debian/:
     - Add docs file, installing README.
     - Add install file, installing actual data.
+  * debian/postinst:
+    - Sync with debian-archive-keyring package.
 
  -- Mike Gabriel <mike.gabriel at das-netzwerkteam.de>  Wed, 09 Jul 2014 20:10:47 +0200
 
diff --git a/debian/postinst b/debian/postinst
index 8ddd7d1..b4ad35b 100644
--- a/debian/postinst
+++ b/debian/postinst
@@ -1,5 +1,19 @@
-#!/bin/sh -e
+#!/bin/sh
 
-if which apt-key >/dev/null; then
-    echo -n "Updating APT keyring - " && apt-key add /usr/share/keyrings/x2go-keyring.gpg
+set -e
+
+if [ "$1" = 'configure' -a -n "$2" ]; then
+	# remove keys from the trusted.gpg file as they are now shipped in fragment files in trusted.gpg.d
+	if dpkg --compare-versions "$2" 'lt' "2019.1" && which gpg > /dev/null && which apt-key > /dev/null; then
+		TRUSTEDFILE='/etc/apt/trusted.gpg'
+		eval $(apt-config shell TRUSTEDFILE Apt::GPGV::TrustedKeyring)
+		eval $(apt-config shell TRUSTEDFILE Dir::Etc::Trusted/f)
+		if [ -e "$TRUSTEDFILE" ]; then
+			for KEY in C509840B96F89133 E1F958385BFE2B6E; do
+				apt-key --keyring "$TRUSTEDFILE" del $KEY > /dev/null 2>&1 || :
+			done
+		fi
+	fi
 fi
+
+#DEBHELPER#

--
Alioth's /home/x2go-admin/maintenancescripts/git/hooks/post-receive-email on /srv/git/code.x2go.org/x2go-keyring.git


More information about the x2go-commits mailing list