8000 [Console] Separate formatter for stdout/stderr by alcohol · Pull Request #13661 · symfony/symfony · GitHub
[go: up one dir, main page]

Skip to content

[Console] Separate formatter for stdout/stderr #13661

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

Closed
wants to merge 4 commits into from
Closed
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Merge branch '2.3' of github.com:symfony/symfony into separate-format…
…ter-per-stdout-stderr

* '2.3' of github.com:symfony/symfony: (273 commits)
  #15331 add infos about deprecated classes to UPGRADE-3.0
  [Security] removed useless else condition in SwitchUserListener class.
  [travis] Tests deps=low with PHP 5.6
  [Console] Fix console output with closed stdout
  [Security] fix check for empty usernames
  [Form] updated exception message of ButtonBuilder::setRequestHandler()
  [travis] Fix deps=high jobs
  [HttpFoundation] [PSR-7] Allow to use resources as content body and to return resources from string content
  [DependencyInjection] Remove unused code in XmlFileLoader
  [HttpFoundation] Behaviour change in PHP7 for substr
  bumped Symfony version to 2.3.32
  updated VERSION for 2.3.31
  update CONTRIBUTORS for 2.3.31
  updated CHANGELOG for 2.3.31
  fixed some tests
  Remove excess whitespace
  Added 'default' color
  [HttpFoundation] Reload the session after regenerating its id
  [HttpFoundation] Add a test case to confirm a bug in session migration
  [Finder] Command::addAtIndex() fails with Command instance argument
  ...
  • Loading branch information
alcohol committed Jul 26, 2015
commit 064ceb4f4b21b6842b368eae73b00ddb439b5715
9 changes: 2 additions & 7 deletions src/Symfony/Component/Console/Output/ConsoleOutput.php
Original file line number Diff line number Diff line change
Expand Up @@ -51,18 +51,13 @@ public function __construct(
OutputFormatterInterface $stdoutFormatter = null,
OutputFormatterInterface $stderrFormatter = null
) {
$outputStream = 'php://stdout';
if (!$this->hasStdoutSupport()) {
$outputStream = 'php://output';
}

parent::__construct(fopen($outputStream, 'w'), $verbosity, $decorated, $stdoutFormatter);
parent::__construct($this->openOutputStream(), $verbosity, $decorated, $stdoutFormatter);

if (null === $stderrFormatter) {
$stderrFormatter = clone $this->getFormatter();
}

$this->stderr = new StreamOutput(fopen('php://stderr', 'w'), $verbosity, $decorated, $stderrFormatter);
$this->stderr = new StreamOutput($this->openErrorStream(), $verbosity, $decorated, $stderrFormatter);
}

/**
Expand Down
You are viewing a condensed version of this merge commit. You can view the full changes here.
0