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

Fix issue #172 with tempnam() throwing an Exception. #219

Closed
wants to merge 1 commit into from

Conversation

BrandonSurowiec
Copy link

@BrandonSurowiec BrandonSurowiec commented Dec 18, 2018

I have a Homestead server setup on my Windows PC for Laravel development.

When I run a command in my local CLI that calls PHRETS I get an error exception because Window's temporary directory is not "/tmp."

Using sys_get_temp_dir() will return the correct path for PHP's temporary file store for the current environment. On Linux it will still be /tmp.

I have a Homestead server setup on my Windows PC for development and so my temp directory is not "/tmp" and Laravel throws an ErrorException. The `sys_get_temp_dir()` function returns the default path PHP stores temporary files in. So it will still resolve to `"/tmp"` on Linux, but for Windows it will resolve to the correct temp directory.
@BrandonSurowiec
Copy link
Author

Another option could be to allow the value to be modified through the configuration.

@BrandonSurowiec
Copy link
Author

According to #158, it would be better if we didn't even use a cookie file as they currently are not auto-cleaned up.

@BrandonSurowiec BrandonSurowiec deleted the patch-1 branch June 10, 2022 03:06
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