C2="\033[1m\E[32m" C6="\033[1m\E[36m" C7="\033[1m\E[37m"
TOTL=$(awk '/SwapTotal/{print $2/1024}' /proc/meminfo)
gnome-terminal --title "Clear Swap Partition" --geometry=62x11+0+24 -x\
sudo bash -c "\
${LCTN=$(awk 'NR==2 {print $1}' /proc/swaps)};\
${UUID=$(awk -F'[= ]' '/^UUID.*swap/{print $2}' /etc/fstab)};\
tput clear; tput civis;\
if [[ -z $LCTN || -z $UUID ]]; then\
echo -e '$C6''\n[Error] Can'\''t read location and/or UUID, exiting.';\
read -t10; exit 1;\
fi;\
echo -ne '$C6''Write ''$C7''$TOTL''MiBs''$C6'' of zeros to ';\
echo -e 'swap space on partition ''$C7''$LCTN''$C6\n';\
swapoff -a;\
trap 'killall dcfldd 2> /dev/null; mkswap -U $UUID $LCTN;\
swapon -a; sleep 5; exit' INT TERM EXIT;\
dcfldd if=/dev/zero of=$LCTN statusinterval=2 bs=10M conv=notrunc;\
echo -ne '$C2''\nAll Done.....''$C6''\nRe-mounting swap on partition: ';\
echo -e '$C7''$LCTN''$C6''\nusing UUID: ''$C7''$UUID\n''$C6';\
read -t5"
TODO