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

Change LogFile setting handling #101

Open
stevechilds opened this issue Sep 26, 2016 · 2 comments
Open

Change LogFile setting handling #101

stevechilds opened this issue Sep 26, 2016 · 2 comments

Comments

@stevechilds
Copy link

stevechilds commented Sep 26, 2016

Current the library requires you to specify a log file within the config file - this is not ideal as you may well not know the folder ahead of runtime to put into the file. (e.g. you're in a Symfony app and the folder could be anywhere in relation to the config file).

What I did was set the parameter to './' in the file and then planned to override it with the next line of code, not ideal, but workable.

However, that doesn't work as it assumes the file is already existing when you call setLogPath(). Can you change it so that it doesn't assume the file exists, or at the very least, if it doesn't exist either ignore the error (and don't raise an exception) or simply create it.

Cheers.

@Peardian
Copy link
Collaborator

I see what you mean. I think a good idea would be to add log link as a supported key in the passed config array (discussed in #97). In the meantime, pull request #102 was just created, which creates the log file if it does not exist.

@stevechilds
Copy link
Author

stevechilds commented Sep 26, 2016

Cheers. I'm actually looking at seeing if I can do the config array change now - it depends on how much the config is used internally. if I get it working, I'll create a pull request (I think that's the term, I'm more used to SVN than git).

/Edit the edit - moved comments to other thread.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants