[Xfce4-commits] <xfce-utils:master> Don't try to remove the $HOME directory (bug #8154).

Nick Schermer noreply at xfce.org
Thu Nov 17 21:36:01 CET 2011


Updating branch refs/heads/master
         to 641098cdf256ceede9546375246e9974f2bbed89 (commit)
       from 517a966a3beb24645c5dd6757a5f5c1fdb356054 (commit)

commit 641098cdf256ceede9546375246e9974f2bbed89
Author: Mark Trompell <mark at foresightlinux.org>
Date:   Thu Nov 17 21:34:03 2011 +0100

    Don't try to remove the $HOME directory (bug #8154).
    
    If $XDG_DESKTOP_HOME or $XDG_TEMPLATES_DIR are set to
    $HOME to hide them, we try to migrate them, which is not
    a good idea.

 scripts/xinitrc.in.in |    6 ++++--
 1 files changed, 4 insertions(+), 2 deletions(-)

diff --git a/scripts/xinitrc.in.in b/scripts/xinitrc.in.in
index f582934..e63eac1 100755
--- a/scripts/xinitrc.in.in
+++ b/scripts/xinitrc.in.in
@@ -54,7 +54,8 @@ if test -f "$XDG_CONFIG_HOME/user-dirs.dirs"; then
     # a bit of user dir migration...
     if test -d "$HOME/Desktop" -a ! -L "$HOME/Desktop" \
             -a "$XDG_DESKTOP_DIR" \
-            -a "$HOME/Desktop" != "$XDG_DESKTOP_DIR"
+            -a "$HOME/Desktop" != "$XDG_DESKTOP_DIR" \
+            -a "$HOME" != "$XDG_DESKTOP_DIR"
     then
         echo "Migrating $HOME/Desktop to $XDG_DESKTOP_DIR..."
         test -d "$XDG_DESKTOP_DIR" && rmdir "$XDG_DESKTOP_DIR"
@@ -63,7 +64,8 @@ if test -f "$XDG_CONFIG_HOME/user-dirs.dirs"; then
 
     if test -d "$HOME/Templates" -a ! -L "$HOME/Templates" \
             -a "$XDG_TEMPLATES_DIR" \
-            -a "$HOME/Templates" != "$XDG_TEMPLATES_DIR"
+            -a "$HOME/Templates" != "$XDG_TEMPLATES_DIR" \
+            -a "$HOME" != "$XDG_TEMPLATES_DIR"
     then
         echo "Migrating $HOME/Templates to $XDG_TEMPLATES_DIR..."
         test -d "$XDG_TEMPLATES_DIR" && rmdir "$XDG_TEMPLATES_DIR"


More information about the Xfce4-commits mailing list