synchronous package list updates

master
shark 6 years ago
parent 0136919bd4
commit daa3ead1e1

@ -25,33 +25,36 @@ function pmm
for j in (brl list) for j in (brl list)
if strat $j apt --version > /dev/null 2>&1 if strat $j apt --version > /dev/null 2>&1
echo "Updating the"(set_color green) "$j"(set_color normal) "stratum." echo "Updating the"(set_color green) "$j"(set_color normal) "stratum."
sudo strat $j apt update sudo strat -r $j apt update &
end end
end end
for j in (brl list) for j in (brl list)
if strat $j pacman --version > /dev/null 2>&1 if strat $j pacman --version > /dev/null 2>&1
echo "Updating the"(set_color green) "$j"(set_color normal) "stratum." echo "Updating the"(set_color green) "$j"(set_color normal) "stratum."
sudo strat $j pacman -Sy sudo strat -r $j pacman -Sy &
end end
end end
for j in (brl list) for j in (brl list)
if strat $j xbps-install --version > /dev/null 2>&1 if strat $j xbps-install --version > /dev/null 2>&1
echo "Updating the"(set_color green) "$j"(set_color normal) "stratum." echo "Updating the"(set_color green) "$j"(set_color normal) "stratum."
sudo strat $j xbps-install -S sudo strat -r $j xbps-install -S &
end end
end end
for j in (brl list) for j in (brl list)
if strat $j dnf --version > /dev/null 2>&1 if strat $j dnf --version > /dev/null 2>&1
echo "Updating the"(set_color green) "$j"(set_color normal) "stratum." echo "Updating the"(set_color green) "$j"(set_color normal) "stratum."
sudo strat $j dnf check-update sudo strat -r $j dnf check-update &
end end
end end
for j in (brl list) for j in (brl list)
if strat $j emerge --version > /dev/null 2>&1 if strat $j emerge --version > /dev/null 2>&1
echo "Updating the"(set_color green) "$j"(set_color normal) "stratum." echo "Updating the"(set_color green) "$j"(set_color normal) "stratum."
sudo strat $j emerge --sync sudo strat -r $j emerge --sync &
end end
end end
while jobs -q
wait (jobs -p)
end
end end
if test "$u" = "1" if test "$u" = "1"
for j in (brl list) for j in (brl list)
@ -62,7 +65,7 @@ function pmm
set ncarg set ncarg
end end
echo "Upgrading the"(set_color green) "$j"(set_color normal) "stratum." echo "Upgrading the"(set_color green) "$j"(set_color normal) "stratum."
sudo strat $j apt upgrade $ncarg sudo strat $j apt upgrade $ncarg
end end
end end
for j in (brl list) for j in (brl list)
@ -73,7 +76,7 @@ function pmm
set ncarg set ncarg
end end
echo "Upgrading the"(set_color green) "$j"(set_color normal) "stratum." echo "Upgrading the"(set_color green) "$j"(set_color normal) "stratum."
sudo strat $j pacman -Su $ncarg sudo strat $j pacman -Su $ncarg
end end
end end
for j in (brl list) for j in (brl list)
@ -84,7 +87,7 @@ function pmm
set ncarg set ncarg
end end
echo "Upgrading the"(set_color green) "$j"(set_color normal) "stratum." echo "Upgrading the"(set_color green) "$j"(set_color normal) "stratum."
sudo strat $j xbps-install -u $ncarg sudo strat $j xbps-install -u $ncarg
end end
end end
for j in (brl list) for j in (brl list)
@ -101,17 +104,17 @@ function pmm
for j in (brl list) for j in (brl list)
if strat $j emerge --version > /dev/null 2>&1 if strat $j emerge --version > /dev/null 2>&1
echo "Upgrading the"(set_color green) "$j"(set_color normal) "stratum." echo "Upgrading the"(set_color green) "$j"(set_color normal) "stratum."
sudo strat $j emerge -uDU --keep-going --with-bdeps=y @world sudo strat $j emerge -uDU --keep-going --with-bdeps=y @world
end end
end end
for j in (brl list) for j in (brl list)
if strat $j swupd --version > /dev/null 2>&1 if strat $j swupd --version > /dev/null 2>&1
echo "Upgrading the"(set_color green) "$j"(set_color normal) "stratum." echo "Upgrading the"(set_color green) "$j"(set_color normal) "stratum."
sudo strat $j swupd update sudo strat $j swupd update
end end
end end
echo "Upgrading the"(set_color green) "bedrock"(set_color normal) "stratum." echo "Upgrading the"(set_color green) "bedrock"(set_color normal) "stratum."
sudo brl update sudo brl update
end end
if test "$ins" = "1" if test "$ins" = "1"
for j in (brl list) for j in (brl list)
@ -223,4 +226,4 @@ function pmm
end end
end end
end end
end end

Loading…
Cancel
Save