Generalize update command

This commit is contained in:
Devon Tingley 2022-10-05 17:28:57 -04:00
parent 1614ab114d
commit 52d97d3f98
2 changed files with 25 additions and 5 deletions

View file

@ -1,5 +0,0 @@
function macos_update
brew upgrade
gup update
cargo install-update --all
end

View file

@ -0,0 +1,25 @@
function update
switch (uname)
case Linux
if type -q yay
yay
end
if type -q flatpak
flatpak update
end
case Darwin
brew upgrade
case '*'
echo "Unsupported OS"
exit 1
end
if type -q gup
gup update
end
if type -q cargo
cargo install-update --all
end
end