mirror of
https://gitea.blesmrt.net/mikaela/scripts.git
synced 2025-06-15 03:27:20 +02:00
deb-update.bash: a bit better rpm-ostree detection
This commit is contained in:
parent
a67afa9b4b
commit
3b9d98bc0e
@ -38,8 +38,9 @@ if hash fedora-third-party 2> /dev/null; then
|
|||||||
fedora-third-party query
|
fedora-third-party query
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# TODO: Better way of identifying Fedora Atomic! There is the overlayfs thing?
|
# If we have a /sysroot/ostree chances are we are on Fedora Atomic and
|
||||||
if [[ -f /usr/bin/dnf && ! -d /var/roothome ]]; then
|
# should use rpm-ostree instead of dnf
|
||||||
|
if [[ -f /usr/bin/dnf && ! -d /sysroot/ostree ]]; then
|
||||||
# I don't know if -y does anything here either and I think this may be
|
# I don't know if -y does anything here either and I think this may be
|
||||||
# useless, but I am used to it coming from apt and I think it will just
|
# useless, but I am used to it coming from apt and I think it will just
|
||||||
# say nothing to do or do nothing if mirrors haven't updated.
|
# say nothing to do or do nothing if mirrors haven't updated.
|
||||||
@ -57,8 +58,7 @@ if [[ -f /usr/bin/dnf && ! -d /var/roothome ]]; then
|
|||||||
|
|
||||||
# potentially unsafe, see a few lines above and the apt-get section
|
# potentially unsafe, see a few lines above and the apt-get section
|
||||||
dnf "$@" autoremove
|
dnf "$@" autoremove
|
||||||
# TODO: Better way of identifying Fedora Atomic! There is the overlayfs thing?
|
elif [[ -f /usr/bin/rpm-ostree && -d /sysroot/ostree ]]; then
|
||||||
elif [[ -f /usr/bin/rpm-ostree && -d /var/roothome ]]; then
|
|
||||||
rpm-ostree upgrade
|
rpm-ostree upgrade
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user