Packages zenity and xterm must be installed and the script must be executable (chmod +x the-script)
zenity --question --text "Would you like to check and install updates?"
if [ $? = 0 ];
xterm -e su -c 'xterm -e zypper update && zypper -y upgrade' root && zenity --info --text "System Upgraded"
else exit 0
Read also openSUSE and deltarpm update