diff --git a/fish/functions/macos_update.fish b/fish/functions/macos_update.fish deleted file mode 100644 index 58d4805..0000000 --- a/fish/functions/macos_update.fish +++ /dev/null @@ -1,5 +0,0 @@ -function macos_update - brew upgrade - gup update - cargo install-update --all -end diff --git a/fish/functions/update.fish b/fish/functions/update.fish new file mode 100644 index 0000000..dcfad92 --- /dev/null +++ b/fish/functions/update.fish @@ -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