mirror of
https://github.com/dustinkirkland/byobu
synced 2025-08-14 18:57:20 -07:00
added support for dnf package manager
https://code.launchpad.net/~sanjay-ankur/byobu/byobu/+merge/415959
This commit is contained in:
parent
63df0a8c8e
commit
fc1b4580a8
2 changed files with 10 additions and 1 deletions
|
@ -85,6 +85,9 @@ ___update_cache() {
|
|||
# Wolfi updates are cheap (~1s); so update cache every time
|
||||
apk update 2>&1 >/dev/null
|
||||
apk upgrade --simulate | grep -c " Upgrading " >$mycache 2>/dev/null &
|
||||
elif eval $BYOBU_TEST dnf >/dev/null; then
|
||||
# If dnf exists, use it
|
||||
flock -xn "$flock" dnf list --upgrades -q -y | grep -vc "Available Upgrades" >$mycache 2>/dev/null &
|
||||
fi
|
||||
}
|
||||
|
||||
|
@ -141,6 +144,9 @@ ___update_needed() {
|
|||
# formulae database was updated
|
||||
[ "$(brew --prefix)/Library/Formula" -nt "$mycache" ]
|
||||
return $?
|
||||
elif [ -e "/var/cache/dnf/packages.db" ]; then
|
||||
[ "/var/cache/dnf/packages.db" -nt "$mycache" ]
|
||||
return $?
|
||||
fi
|
||||
return 1
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue