Fix /tmp addition
authorJoerg Jaspert <joerg.jaspert@dlh.de>
Fri, 16 Sep 2016 10:44:22 +0000 (12:44 +0200)
committerJoerg Jaspert <joerg.jaspert@dlh.de>
Fri, 16 Sep 2016 10:44:22 +0000 (12:44 +0200)
.zsh/10_Environment.zsh

index ea07091..a68052c 100644 (file)
@@ -63,15 +63,15 @@ fi
 # (say /run/user/$uid), and if so, point TMPDIR there. We use
 # a subdir there to avoid interfering with other stuff
 if zstyle -T ':ganneff:config' runtmp; then
-    rudir="$(df -t tmpfs --output=target|grep ${UID} || true)/tmp"
+    rudir="$(df -t tmpfs --output=target|grep ${UID} || true)"
 fi
 
 # Ignore existing TMPDIR variable and always repoint...
 if zstyle -T ':ganneff:config' resettmpdir; then
-    export TMPDIR="${rudir:-$HOME/tmp}"
+    export TMPDIR="${rudir:-$HOME}/tmp"
 else
     # ... or not
-    (( ${+TMPDIR} )) || export TMPDIR="${rudir:-$HOME/tmp}"
+    (( ${+TMPDIR} )) || export TMPDIR="${rudir:-$HOME}/tmp"
 fi
 
 # Ensure the tmpdir exists