This is an automated email from the git hooks/post-receive script. x2go pushed a commit to branch release/4.0.1.x in repository x2goserver. commit 79681a1bd387833d351e6dbe2dcf8120af52e451 Author: Mihai Moldovan <ionic@ionic.de> Date: Mon Feb 12 00:05:42 2018 +0100 x2goserver.spec: backport /etc/x2g/applications behavior from upstream Fedora spec file. Own the file as part of a %ghost procedure and make sure that the removal is only executed on real package erases (i.e., not also during package upgrades). --- debian/changelog | 4 ++++ x2goserver.spec | 16 +++++++++++++--- 2 files changed, 17 insertions(+), 3 deletions(-) diff --git a/debian/changelog b/debian/changelog index b515ee7..d732421 100644 --- a/debian/changelog +++ b/debian/changelog @@ -100,6 +100,10 @@ x2goserver (4.0.1.23-0x2go1) UNRELEASED; urgency=medium use/have systemd. - Actually install /etc/sudoers.d/x2goserver conffile on non-SuSE systems. Got broken accidentally a while ago. + - Backport /etc/x2g/applications behavior from upstream Fedora spec file. + Own the file as part of a %ghost procedure and make sure that the + removal is only executed on real package erases (i.e., not also during + package upgrades). * debian/x2goserver.install: - Install new /etc/tmpfiles.d/x2goserver.conf conffile. diff --git a/x2goserver.spec b/x2goserver.spec index d98422d..e8df4b8 100644 --- a/x2goserver.spec +++ b/x2goserver.spec @@ -495,6 +495,10 @@ fi %service_add_pre x2goserver.service %endif +# Dummy file - will be created/removed in post* scriptlets. +# We just need this here for the %ghost directory to work. +touch "%{buildroot}/%{_sysconfdir}/x2go/applications" + %post # Initialize the session database if [ ! -s %{_localstatedir}/lib/x2go/x2go_sessions ]; then @@ -536,8 +540,10 @@ fi %endif %preun -if [ -L %{_sysconfdir}/x2go/applications ]; then - rm -f %{_sysconfdir}/x2go/applications || : +if [ "${1}" = "0" ]; then + if [ -L %{_sysconfdir}/x2go/applications ]; then + rm -f %{_sysconfdir}/x2go/applications || : + fi fi %if 0%{?fedora} || 0%{?rhel} >= 7 || 0%{?suse_version} >= 1210 @@ -650,7 +656,11 @@ fi %config(noreplace) %{_sysconfdir}/sudoers.d/x2goserver %endif %dir %{_sysconfdir}/x2go/ -%config(noreplace) %{_sysconfdir}/x2go/x2go* +%ghost %config(noreplace) %{_sysconfdir}/x2go/applications +%config(noreplace) %{_sysconfdir}/x2go/x2go_logout +%config(noreplace) %{_sysconfdir}/x2go/x2go_logout.d/ +%config(noreplace) %{_sysconfdir}/x2go/x2goserver.conf +%config(noreplace) %{_sysconfdir}/x2go/x2gosql/ %if 0%{?fedora} || 0%{?rhel} >= 7 || 0%{?suse_version} >= 1210 %config(noreplace) %{_sysconfdir}/tmpfiles.d/x2goserver.conf %endif -- Alioth's /home/x2go-admin/maintenancescripts/git/hooks/post-receive-email on /srv/git/code.x2go.org/x2goserver.git