# Short alias for installing gems using Bundler.
function brew_update
    # This can only be run by an admin user
    if not user_is_admin
        exit 1
    end

    brew update
    and brew upgrade

    firewall_allow_nginx
end

# Short alias for installing gems using Bundler.
function brew_update
    # Verify the user owns the Homebrew dir.
    set brew_home (brew --prefix)
    if not test (stat -f%u $brew_home) -eq (id -u $USER)
        echo "You must be the owner of $brew_home to run this command."
        return 1
    end

    brew update
    and brew upgrade

    firewall_allow_nginx
end

Check for ownership of brew home instead of admin status
Check for ownership of brew home instead of admin status

phatblat/dotfiles,phatblat/dotfiles,phatblat/dotfiles,phatblat/dotfiles,phatblat/dotfiles,phatblat/dotfiles