From a27bbc78b37e1c8d8c4caa151368051184ff31d1 Mon Sep 17 00:00:00 2001 From: madomado Date: Sun, 10 Nov 2024 02:22:36 +0800 Subject: [PATCH] fix: dnf5-default-package-manager (#92) fixes https://github.com/Ultramarine-Linux/triage/issues/66 --- .../dnf5-default-package-manager.spec | 17 +++++++++++++---- 1 file changed, 13 insertions(+), 4 deletions(-) diff --git a/ultramarine/dnf5-default-package-manager/dnf5-default-package-manager.spec b/ultramarine/dnf5-default-package-manager/dnf5-default-package-manager.spec index 637b054..5e469f5 100644 --- a/ultramarine/dnf5-default-package-manager/dnf5-default-package-manager.spec +++ b/ultramarine/dnf5-default-package-manager/dnf5-default-package-manager.spec @@ -2,7 +2,7 @@ Name: dnf5-default-package-manager Version: 0 -Release: 2%?dist +Release: 3%?dist Summary: Package that sets dnf5 as the default package manager License: MIT URL: https://wiki.ultramarine-linux.org/en/usage/um40-dnf5/ @@ -15,6 +15,7 @@ This package contains post-install hooks that symlinks %_bindir/dnf to the new dnf5 binary. %prep +touch .placeholder %build @@ -28,9 +29,14 @@ if [ $1 -gt 1 ]; then fi %preun -rm %_bindir/{dnf,yum} -ln -s /usr/bin/dnf-3 /usr/bin/dnf -ln -s %_bindir/dnf-3 /usr/bin/yum +echo +echo "dnf5-default-package-manager will be uninstalled." +echo "If you want to revert the symlinks, run the following commands:" +echo "rm %_bindir/{dnf,yum}" +echo "ln -s /usr/bin/dnf-3 /usr/bin/dnf" +echo "ln -s %_bindir/dnf-3 /usr/bin/yum" +echo "For more information, visit: %url" +echo %triggerin -- dnf rm %_bindir/{dnf,yum} @@ -41,3 +47,6 @@ ln -s %_bindir/dnf5 /usr/bin/yum rm %_bindir/{dnf,yum} ln -s %_bindir/dnf5 /usr/bin/dnf ln -s %_bindir/dnf5 /usr/bin/yum + +%files +%doc .placeholder