You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
There is already a standard to override the temporary directory used by go when creating a new directory.
On Unix systems, it returns $TMPDIR if non-empty, else /tmp.
On Windows, it uses GetTempPath, returning the first non-empty value from %TMP%, %TEMP%, %USERPROFILE%, or the Windows directory.
We should remove the flag and tell people to use these environment variables instead if they want to override the temp directory. We should also remove use to the helpers function to create the temporary directory in favor of stdlib.
Describe what should be investigated or refactored
Currently we have a
--tmpdir
flag in the root command. This allows users to set a custom directory to use for their temp directory.Using this flag requires use to pass the configured flag every time we want to create a temporary directory.
zarf/src/pkg/packager/sources/url.go
Line 56 in 87dfbcd
There is already a standard to override the temporary directory used by go when creating a new directory.
On Unix systems, it returns $TMPDIR if non-empty, else /tmp.
On Windows, it uses GetTempPath, returning the first non-empty value from %TMP%, %TEMP%, %USERPROFILE%, or the Windows directory.
We should remove the flag and tell people to use these environment variables instead if they want to override the temp directory. We should also remove use to the helpers function to create the temporary directory in favor of stdlib.
Links to any relevant code
zarf/src/cmd/root.go
Line 131 in 87dfbcd
The text was updated successfully, but these errors were encountered: