Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add make-temp-dir and friends #190

Closed
wants to merge 1 commit into from
Closed

Conversation

sogaiu
Copy link
Contributor

@sogaiu sogaiu commented Jul 19, 2024

This is an attempt to address #189 including some tests.

There are four functions:

  • make-temp-dir
  • temp-root
  • windows-temp-root
  • posix-temp-root

make-temp-dir tries to create a temporary directory that lives under some temporary directory that a system already has (the function temp-root tries to determine this) and tries to do so according to a template.

windows-temp-root and posix-temp-root are supporting functions for the temp-root function.

See the docstring of each for details.

I'm not certain what temp-root should return for MinGW and Cygwin setups. For the moment I've gone with /tmp for both. If someone happens to know or can check, I'm happy to modify. Otherwise, may be if these are wrong, they can get corrected later (^^;

@sogaiu
Copy link
Contributor Author

sogaiu commented Jul 23, 2024

Not making much progress getting info about the MinGW and Cygwin cases and may be it wouldn't be bad to get some more experience using the existing code so I'm going to close this for now.


On a related note, @yumaikas has a library called janet-tempfiles that has some intersecting functionality.

@sogaiu sogaiu closed this Jul 23, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant