diff --git a/README.md b/README.md
index 95e0d86e5742a5f3fbf4b3c6a93fe489a5a44c26..1a3584bf131bdb015bcb9834f488b1f4821708a1 100644
--- a/README.md
+++ b/README.md
@@ -1,6 +1,6 @@
# Transfuse
-A script to backup (copy+compress) and restore your plasma desktop configurations.
+A script to backup (copy+compress) and restore KDE Plasma user configurations.
Also includes options to export and use package lists for pacman and the Arch User Repository.
@@ -70,7 +70,13 @@ bash <(curl -s https://gitlab.com/cscs/transfuse/-/raw/main/transfuse)
bash <(curl -s https://gitlab.com/cscs/transfuse/-/raw/main/transfuse) -p
```
-
+
+
+### License
+
+[The Unlicense](/LICENSE)
+
+
### Donate
diff --git a/transfuse b/transfuse
index bed2f60da7044a9831227e0b8814e81f7bda4126..7fd86bfb4a8655eb3c13338c8a278060f7dc8552 100755
--- a/transfuse
+++ b/transfuse
@@ -65,13 +65,17 @@ _tr_copywpf() {
if [ -z "$TR_COVER" ]; then
mkdir -p ./"$DONOR"_transfusion_"$NOW"/.local/share/wallpapers;
OLDFLWR=$(awk -F: '/\[Wallpaper\]\[org\.kde\.image\]/ && $0 != "" { getline; print $1 }' /home/"$DONOR"/.config/plasma-org.kde.plasma.desktop-appletsrc | awk '{ sub(/(Image=){1}/, "") }1 && !/^file$/')
- AROSE=$(basename -- "$OLDFLWR")
- PETAL="${AROSE##*.}"
- if [ "$TR_USECP" = 1 ] || ! command -v rsync >/dev/null 2>&1;
- then
- cp -drf --preserve=mode,timestamps "$OLDFLWR" ./"$DONOR"_transfusion_"$NOW"/.local/share/wallpapers/flowers."$PETAL";
+ if [ -f "$OLDFLWR" ]; then
+ AROSE=$(basename -- "$OLDFLWR")
+ PETAL="${AROSE##*.}"
+ if [ "$TR_USECP" = 1 ] || ! command -v rsync >/dev/null 2>&1;
+ then
+ cp -drf --preserve=mode,timestamps "$OLDFLWR" ./"$DONOR"_transfusion_"$NOW"/.local/share/wallpapers/flowers."$PETAL";
+ else
+ _tr_cp "$OLDFLWR" ./"$DONOR"_transfusion_"$NOW"/.local/share/wallpapers/flowers."$PETAL";
+ fi
else
- _tr_cp "$OLDFLWR" ./"$DONOR"_transfusion_"$NOW"/.local/share/wallpapers/flowers."$PETAL";
+ echo -e "\n Wallpaper could not be found.";
fi
else
echo -e "\n You are \"Covered\" so the wallpaper selection was not copied.";
@@ -232,7 +236,11 @@ _tr_refrkde() {
fi;
if [ -z "$TR_COVER" ]; then
NEWFLWR=$(find /home/"$PATIENT"/.local/share/wallpapers -name "flowers.*");
- plasma-apply-wallpaperimage "$NEWFLWR" ;
+ if [ -f "$NEWFLWR" ]; then
+ plasma-apply-wallpaperimage "$NEWFLWR" ;
+ else
+ echo -e "\n No wallpaper found.";
+ fi
else
echo -e "\n You are \"Covered\" so no change will be made to the wallpaper selection.";
fi;