cat >> ~/.bashrc <<EOF
rs ()
{
        sudo systemctl restart $1
        sleep 1
        sudo systemctl status $1
}

source /usr/share/bash-completion/completions/systemctl

_systemctl_restart()
{
        comps=$( __get_restartable_units --system "${COMP_WORDS[1]}" )
        compopt -o filenames
        COMPREPLY=( $(compgen -o filenames -W '$comps') )
        return 0
}

complete -F _systemctl_restart rs
EOF