mirror of
https://github.com/vlang/v.git
synced 2025-09-13 14:32:26 +03:00
os,tools: add os.vtmp_dir()
Use it to consistently place all temporary files created by tests in a overridable folder specific to the user, that is easy to cleanup later. NOTE: os.temp_dir() on macos returns `/tmp`, and using `/tmp/v` is a problem when multiple unix users are trying to access/create/write to it.
This commit is contained in:
parent
509f5c7db3
commit
f427a5241a
44 changed files with 114 additions and 105 deletions
|
@ -21,7 +21,7 @@ const (
|
|||
show_progress = os.getenv('GITHUB_JOB') == '' && '-silent' !in os.args
|
||||
non_option_args = cmdline.only_non_options(os.args[2..])
|
||||
is_verbose = os.getenv('VERBOSE') != ''
|
||||
vcheckfolder = os.join_path(os.temp_dir(), 'v', 'vcheck_$os.getuid()')
|
||||
vcheckfolder = os.join_path(os.vtmp_dir(), 'v', 'vcheck_$os.getuid()')
|
||||
should_autofix = os.getenv('VAUTOFIX') != ''
|
||||
vexe = @VEXE
|
||||
)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue