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

Extension, filename and prefix not applying #48

Closed
tleb opened this issue Apr 9, 2015 · 5 comments
Closed

Extension, filename and prefix not applying #48

tleb opened this issue Apr 9, 2015 · 5 comments

Comments

@tleb
Copy link

tleb commented Apr 9, 2015

Hello,

for some reason, the extension, filename and prefix settings do not apply.

$ composer clearcache
$ mkdir test
$ cd test
$ composer require katzgrau/klogger
$ touch index.php

In index.php:

<?php

require 'vendor/autoload.php';

$logger = new Katzgrau\KLogger\Logger(__DIR__, Psr\Log\LogLevel::DEBUG, array (
    'extension' => 'log'
));
$logger->error('error content');

It creates the log file, but in standard format log_2015-04-09.txt. Any explanation? Is it linked to my environment, so that I am the only one to have this issue?

@onno-vos-dev
Copy link
Contributor

You're using the outdated Katzgrau when you pull it in like that.

Use: composer require katzgrau/klogger:dev-master

instead to pull in the latest master branch. Then your code runs fine and I'm getting the correct file type :)

@tleb
Copy link
Author

tleb commented Apr 9, 2015

Sad it's not written anywhere. Even the README recommends using composer require katzgrau/klogger:1.0.*, which would lead to the same problem.

Why is it not 1.0.1 ?

@onno-vos-dev
Copy link
Contributor

I just opened an issue for this :)

@tleb
Copy link
Author

tleb commented Apr 9, 2015

Works now. 😄 Am I the first one to fall into this? Oo

@onno-vos-dev
Copy link
Contributor

Nope, @drasive fell for this as well as can be seen in #46

I'll submit a PR on the weekend to address this.

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

No branches or pull requests

3 participants