#!/bin/sh

plugin_short="tobayer01"
plugin_type="swapskin"
plugin_target="/var/swap/titanskins"

plugin_dir="$plugin_target/$plugin_short"
plugin="$plugin_short $plugin_type"


### FUNCTIONS ###

RES_COL=60									# column number to place the status

echo_success() {							# function to print the OK status
	printf "%-${RES_COL}s%s\n" "$1" "[  OK  ]"
}

echo_failure() {							# function to print the FAILED status
	printf "%-${RES_COL}s%s\n" "$1" "[FAILED]"
}



### MAIN ###

sync
SPACE=`getfreespace $plugin_target`
FREE=`expr $SPACE - 100`
echo "Old free space: $FREE kB"


msg="Removing $plugin..."
echo_success "$msg"

exit 0
