CWD=`pwd`
+#
+# Set your home directory here (do not use $HOME !!!)
+#
+MY_HOME=/home/xxx
+
#
# The device name of your USB device (e.g. /dev/sda)
# You can find it by plugging it in then doing
--- /dev/null
+#!/bin/sh
+#
+# If you are running on a Kubuntu desktop and you would like to have
+# the same desktop on the usb key, you can do so by running this
+# script. You must be root.
+#
+. ./config
+
+if [ ! `whoami` = "root" ] ; then
+ echo ""
+ echo "You need to be root to run this shell script"
+ echo ""
+ exit 1
+fi
+
+if [ ! -d ${MOUNT_POINT}/home-rw ] ; then
+ mkdir -p ${MOUNT_POINT}/home-rw
+ created="yes"
+fi
+mount ${USB_DEV}3 ${MOUNT_POINT}/home-rw
+if [ $? -ne 0 ] ; then
+ echo "Mount of home-rw USB partition failed."
+ exit 1
+fi
+cd ${MOUNT_POINT}/home-rw
+if [ $? -ne 0 ] ; then
+ echo "Could not cd to home-rw USB partition"
+ exit 1
+fi
+
+mkdir -p ubuntu
+chown 1000:1000 ubuntu
+cd ubuntu
+# Do files
+for i in .bashrc .bash_logout ; do
+ if [ -f ${MY_HOME}/$i ] ; then
+ cp ${MY_HOME}/$i .
+ chown 1000:1000 $i
+ fi
+done
+#
+# Special case for .kde
+#
+echo "Copying .kde ..."
+mkdir .kde
+cd .kde
+cp -a $MY_HOME/.kde/share .
+chown -R 1000:1000 .kde
+cd ..
+
+# Do directories
+for i in .gnupg .ssh .mozilla ; do
+ if [ -d ${MY_HOME}/$i ] ; then
+ cp -a ${MY_HOME}/$i .
+ chown -R 1000:1000 $i
+ fi
+done