On 14/08/2026 15:28 BST Mark J. Reed <markjreed@xxxxxxxxx> wrote:
>
>
> How does TMPPREFIX get initialized? At least on my Mac, it's not set
> in the environment before zsh starts - but TMPDIR is, set by the OS.
> It seems like in that case zsh should initialize TMPPREFIX using
> TMPDIR instead of /tmp. If I were writing the initialization as a ?> shell command I'd probably go with this:
>
> : "${TMPPREFIX:=${TMPDIR:-/tmp}/zsh}}"
The zsh source code doesn't treat TMPDIR as special at all, so this
looks to me like something to go in an initialisation file, indeed
it looks like it would make sense in a general system initialisation
file.
pws