[Monolog] Added a way to configure the ConsoleFormatter from the ConsoleHandler#30345
Merged
fabpot merged 1 commit intosymfony:masterfrom Feb 23, 2019
Merged
[Monolog] Added a way to configure the ConsoleFormatter from the ConsoleHandler#30345fabpot merged 1 commit intosymfony:masterfrom
fabpot merged 1 commit intosymfony:masterfrom
Conversation
nicolas-grekas
approved these changes
Feb 23, 2019
Member
|
The configuration you have in the description should be the default one, right? Is it possible to make it the default in the bundle? Or at least, add this snippet in the recipe? |
fabpot
approved these changes
Feb 23, 2019
Member
|
Thank you @lyrixx. |
fabpot
added a commit
that referenced
this pull request
Feb 23, 2019
…r from the ConsoleHandler (lyrixx) This PR was merged into the 4.3-dev branch. Discussion ---------- [Monolog] Added a way to configure the ConsoleFormatter from the ConsoleHandler | Q | A | ------------- | --- | Branch? | master | Bug fix? | no | New feature? | yes | BC breaks? | no | Deprecations? | no | Tests pass? | yes | Fixed tickets | - | License | MIT | Doc PR | see also symfony/monolog-bundle#297 from that:  to that:  with some configuration: ```yaml diff --git a/config/packages/dev/monolog.yaml b/config/packages/dev/monolog.yaml index b1998da..66ae2db 100644 --- a/config/packages/dev/monolog.yaml +++ b/config/packages/dev/monolog.yaml @@ -17,3 +17,6 @@ monolog: type: console process_psr_3_messages: false channels: ["!event", "!doctrine", "!console"] + console_formater_options: + format: "%%datetime%% %%start_tag%%%%level_name%%%%end_tag%% <comment>[%%channel%%]</> %%message%%%%context%%\n" + multiline: false ``` Commits ------- 5e494db [Monolog] Added a way to configure the ConsoleFormatter from the ConsoleHandler
Member
Author
It's really a matter of taste. But I could send a PR with commented configuration. WDYT ? |
lyrixx
added a commit
to symfony/monolog-bundle
that referenced
this pull request
Mar 12, 2019
This PR was merged into the 3.x-dev branch.
Discussion
----------
Expose configuration for the ConsoleHandler
Like that we will be able to use this configuration (for example):
```yaml
console:
type: console
process_psr_3_messages: false
channels: ["!event", "!doctrine", "!console"]
console_formater_options:
format: "%%datetime%% %%start_tag%%%%level_name%%%%end_tag%% <comment>[%%channel%%]</> %%message%%%%context%%\n"
multiline: false
```
see also symfony/symfony#30345
Commits
-------
cc9abf6 Expose configuration for the ConsoleHandler
Member
Author
|
Here we go: symfony/recipes#552 |
Merged
2 tasks
dani-danigm
pushed a commit
to dani-danigm/monolog-bundle
that referenced
this pull request
Jun 15, 2022
dani-danigm
pushed a commit
to dani-danigm/monolog-bundle
that referenced
this pull request
Jun 15, 2022
This PR was merged into the 3.x-dev branch.
Discussion
----------
Expose configuration for the ConsoleHandler
Like that we will be able to use this configuration (for example):
```yaml
console:
type: console
process_psr_3_messages: false
channels: ["!event", "!doctrine", "!console"]
console_formater_options:
format: "%%datetime%% %%start_tag%%%%level_name%%%%end_tag%% <comment>[%%channel%%]</> %%message%%%%context%%\n"
multiline: false
```
see also symfony/symfony#30345
Commits
-------
5605600 Expose configuration for the ConsoleHandler
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
see also symfony/monolog-bundle#297
from that:

to that:

with some configuration: