# # Define $TMPDIR and other stuff related to temporary files # # Copyright © 1994–2017 martin f. krafft # Released under the terms of the Artistic Licence 2.0 # # Source repository: http://git.madduck.net/v/etc/zsh.git # export TMPDIR="/tmp/${(%):-%n}" mkdir --mode=700 --parent "${TMPDIR}" typeset -l LTMPDIR="${HOME}/.tmp" if [ -d $LTMPDIR ]; then typeset -l VOLATILE="${LTMPDIR}/volatile" [ -L "$VOLATILE" ] || ln -snfT "$TMPDIR" "$VOLATILE" nTMPDIR=$LTMPDIR fi TMPPREFIX="${TMPDIR}/zsh" # vim:ft=zsh