#!/bin/bash SOURCE_DIR=$(chezmoi source-path) . "$SOURCE_DIR/scripts/utils_install" && . "$SOURCE_DIR/scripts/utils" empty_macos_trash() { osascript <<'APPLESCRIPT' try tell application "Finder" to empty trash on error number -128 -- User canceled. Not fatal. end try APPLESCRIPT } execute "fish -c 'fish_update_completions'" "Update fish completions" execute "ai-update" "Update AI tools" execute "tv update-channels" "Update Television channels" execute "obsidian-update" "Update Obsidian plugins and themes" if command -v save-to-spotify >/dev/null 2>&1; then execute "save-to-spotify update" "Update save-to-spotify CLI" fi execute "brew cleanup" "Cleanup brew" execute "nvim --headless -c 'autocmd User MasonUpdateAllComplete qall' -c 'MasonUpdateAll'" "Update Neovim Mason packages" ask_for_confirmation "📊 Do you want to update gcx Agent Skills?" if answer_is_yes; then gcx agent skills install --all --force fi ask_for_confirmation "Run Mole?" if answer_is_yes; then mo clean mo optimize fi execute "backup do" "Backup" ask_for_confirmation "Empty macOS Trash?" if answer_is_yes; then empty_macos_trash fi ask_for_confirmation "Do you want to restart your computer?" if answer_is_yes; then sudo shutdown -r now fi