#!/bin/sh

OPTION=`Xdialog --title "SAMBA Control" --menu "Select Option:" 12 50 5 \
start "Start SAMBA service" \
stop "Stop SAMBA service" \
restart "Restart SAMBA service" \
config "Edit SAMBA config file" \
2>&1`

case $OPTION in
    start)
	/etc/rc.d/init.d/samba start
	;;
    stop)
	/etc/rc.d/init.d/samba stop
	;;
    restart)
	/etc/rc.d/init.d/samba restart
	;;
    config)
        leafpad /etc/samba/smb.conf
	;;
esac

