2020-01-26 17:28:29 +01:00
|
|
|
#!/bin/sh
|
|
|
|
#
|
|
|
|
|
2021-03-08 18:23:46 +01:00
|
|
|
REPLACE_FOLDERS="Audio Bilder data Dokumente Downloads eclipse Musik prj Schreibtisch Videos"
|
2020-01-26 17:28:29 +01:00
|
|
|
|
|
|
|
|
2021-01-14 05:00:32 +01:00
|
|
|
echo The following folders will be deleted:
|
|
|
|
for folder in $REPLACE_FOLDERS; do
|
|
|
|
echo "* $HOME/\033[1m$folder\033[0m"
|
2020-01-26 17:28:29 +01:00
|
|
|
done
|
2021-01-14 05:00:32 +01:00
|
|
|
echo
|
|
|
|
read -r -p "Are you sure? [y/N] " response
|
|
|
|
case "$response" in
|
|
|
|
[yY][eE][sS]|[yY])
|
|
|
|
for folder in $REPLACE_FOLDERS; do
|
|
|
|
if [ "$folder" = "data" ]; then
|
|
|
|
rm -f $HOME/data; ln -s /usr/data/$USER $HOME/data
|
|
|
|
else
|
|
|
|
rm -rf $HOME/$folder; ln -s /usr/data/$USER/$folder $HOME
|
|
|
|
fi
|
|
|
|
done
|
|
|
|
;;
|
|
|
|
*)
|
|
|
|
echo No folder initialisation!
|
|
|
|
;;
|
|
|
|
esac
|