Closed kurtbahartr closed 1 month ago
I'll look into Bazzite and try to fix then. Thanks for the various suggestions, I guess the hacky way'd be good enough to fix it (?)
You don't explicitly need Bazzite for that. Even Fedora Silverblue/Kinoite itself suffices. And you're welcome, yeah the hacky way should do for now.
Tried with this approach:
But here's the result :/ I believe they're installing fine but need a reboot to work properly as 7z isn't found later on in the script.
Hmm yeah the apply-live
function isn't that great when --allow-inactive
flag is used in install
. Though the requirement to reboot is the caveat of being immutable - You're effectively switching "commits" between reboots, the latest commit being the one you boot into.
EDIT: I think I have an idea but it's still far too complicated: Try to proceed anyway and when a command fails and the script detects an immutable distro, ask the user to perform a reboot and rerun the script. It's like "Hey I failed to do this action. Maybe a reboot can help mitigate this somehow?".
After some back and forth over on Discord, the issue has finally been resolved. Thanks for the cooperation and attention Nello!
So I wanted to use osu-winello on Bazzite, a Universal Blue project based on Fedora Atomic Desktops (Fedora Silverblue and Fedora Kinoite), and since the installation script doesn't check for the presence of
rpm-ostree
and jumps straight into usage ofdnf
, which is mapped as a wrapper forrpm-ostree
on immutable versions, I get the following error because some, or all, of these packages are already installed;Checking for the presence of
rpm-ostree
and using that instead along with the flag--allow-inactive
could be a hacky, lazy but more global and the least energy consuming way of mitigating this issue.Another way could be writing out what packages we tried to install when it failed and asking user to do manual intervention and then rerun the script with
--no-deps
since we should already have the dependencies installed by then. However, this would be pretty problematic for someone who jumped into Linux without knowing much about the package managers.One other yet the most efficient and the most unattended way could be checking one file installed by each of the packages respectively and installing what's missing only. For example, that would be
/usr/bin/zenity
forzenity
.There's another thing to keep in mind about such distros: Every package installed by
rpm-ostree
are "overlay packages"/"mutations" so the system has to be restarted completely for these packages to be available. Fedora does provide a way to save you from the reboot with the commandrpm-ostree apply-live
, which has to run as root. What this command does is basically applying the changes systematically and in a simple way on top of your current session if rebooting would be a waste of time at that moment. Of course this won't work if there are packages to be upgraded with the next reboot and there's no--allow-replacement
flag supplied.