Closed mpickering closed 1 year ago
The TMPDIR variable on linux influences the value returned by getTemporaryDirectory but not on windows.
module Main where import System.Directory main = getTemporaryDirectory >>= print
on linux
[nix-shell:~/ghc-clean]$ TMPDIR=$PWD ./TempDir "/home/matt/ghc-clean"
but on windows the variable is ignored.
GHC Issues: https://gitlab.haskell.org/ghc/ghc/-/issues/23348
Windows uses the TMP/TEMP environment variables instead, and that's documented in the library.
TMP
TEMP
Yes that is documented, it seems to be a documentation bug in GHC. Sorry for the confusion.
The TMPDIR variable on linux influences the value returned by getTemporaryDirectory but not on windows.
on linux
but on windows the variable is ignored.
GHC Issues: https://gitlab.haskell.org/ghc/ghc/-/issues/23348