Index: ipk/source.sh4/titanskins_0Acht5Zehn/CONTROL/postinst
===================================================================
--- ipk/source.sh4/titanskins_0Acht5Zehn/CONTROL/postinst	(revision 12781)
+++ ipk/source.sh4/titanskins_0Acht5Zehn/CONTROL/postinst	(revision 23281)
@@ -1,12 +1,32 @@
 #!/bin/sh
-TMP=/tmp/.titanskin
-echo "successfully installed"
-if [ `df | grep /dev/mtdblock | grep var | sed 's/ \+/ /g' | cut -d ' ' -f4 | head -n1 | wc -l` -eq 1 ]; then
-	SPACE=`df | grep /dev/mtdblock | grep var | sed 's/ \+/ /g' | cut -d ' ' -f4 | head -n1`
-	FREE=`expr $SPACE - 100`
-	echo new freespace size $FREE kb
+
+releaseversion=22775
+plugin_short="0Acht5Zehn"
+plugin_type="skin"
+plugin_target="/var/usr/local/share/titan/skin"
+
+plugin_dir="$plugin_target/$plugin_short"
+plugin="$plugin_short $plugin_type"
+
+imageversion=`cat /etc/version | cut -d "_" -f2 | sed 's/M//'`;
+
+
+### MAIN ###
+
+sync
+SPACE=`getfreespace $plugin_target`
+FREE=`expr $SPACE - 100`
+echo
+echo "New free space: ${FREE}kB"
+
+
+if [ "$imageversion" -gt "$releaseversion" ]; then
+	echo "Successfully installed $plugin (non-release version)."
+	# ==> rm skin_release.xml
+	rm $plugin_dir/skin_release.xml
 else
-	echo "syncing disk"
-	sync
+	echo "Successfully installed $plugin (release version)."
+	# ==> mv skin_release.xml skin.xml"
+	mv $plugin_dir/skin_release.xml $plugin_dir/skin.xml
 fi
 
