2024-02-19 21:07:46 -05:00
|
|
|
#!/bin/sh
|
|
|
|
|
2024-03-25 21:56:18 -04:00
|
|
|
alias paru='paru --noconfirm --skipreview'
|
2024-02-19 21:07:46 -05:00
|
|
|
alias zigup='zigup --install-dir "${HOME}/.local/share/zigup" --path-link "${HOME}/.local/bin/zig"'
|
|
|
|
|
|
|
|
updates=$(checkupdates)
|
|
|
|
aur_updates=$(paru -Qua)
|
|
|
|
|
|
|
|
if [ "$updates" = "" ] && [ "$aur_updates" = "" ]; then
|
|
|
|
echo "System is already up to date."
|
|
|
|
exit 0
|
|
|
|
fi
|
|
|
|
|
|
|
|
river_has_update=$(echo "$aur_updates" | grep -c 'river-git')
|
|
|
|
zls_has_update=$(echo "$aur_updates" | grep -c 'zls-git')
|
|
|
|
|
|
|
|
if [ "$river_has_update" -ne 0 ] && [ "$zls_has_update" -ne 0 ]; then
|
|
|
|
zigup 0.11.0
|
2024-03-25 21:56:18 -04:00
|
|
|
paru -Syu river-git
|
2024-02-19 21:07:46 -05:00
|
|
|
zigup master
|
2024-03-25 21:56:18 -04:00
|
|
|
paru -S zls-git
|
2024-02-19 21:07:46 -05:00
|
|
|
elif [ "$river_has_update" -ne 0 ]; then
|
|
|
|
zigup 0.11.0
|
|
|
|
paru -Syu
|
|
|
|
zigup master
|
|
|
|
else
|
|
|
|
zigup master
|
|
|
|
paru -Syu
|
|
|
|
fi
|