#! /bin/sh

if [ -z "$DISPLAY" ] ; then
	echo Authentication is needed to run system-switch-mail as super user
	su -c "/usr/share/system-switch-mail/switchmail_tui.py"
else
	/usr/bin/pkexec /usr/share/system-switch-mail/switchmail_gui.py
fi
