private function workaroundForSingleChar(
        string &$incrementalOutput,
        Project $project
    ) {
        // Check if there is a temporarily stored char.
        if (!empty($this->tmpChar[$project->getName()]) && !empty($incrementalOutput)) {
            // Add the char directly at the beginning of the current
            // incremental output value.
            $incrementalOutput = $this->tmpChar[$project->getName()] . $incrementalOutput;
            // Clear the temporarily stored char.
            $this->tmpChar[$project->getName()] = '';
        }
        // If there is a single char store it temporarily.
        if (strlen($incrementalOutput) == 1) {
            $this->tmpChar[$project->getName()] = $incrementalOutput;
            // Clear the current incremental output value so that nothing will be written to the console.
            $incrementalOutput = '';
        }
    }
private function workaroundForSingleChar(
        string &$incrementalOutput,
        Project $project
    ) {
        // Check if there is a temporarily stored char.
        if (!empty($this->tmpChar[$project->getName()]) && !empty($incrementalOutput)) {
            // Add the char directly at the beginning of the current
            // incremental output value.
            $incrementalOutput = $this->tmpChar[$project->getName()] . $incrementalOutput;
            // Clear the temporarily stored char.
            $this->tmpChar[$project->getName()] = '';
        }
        // If there is a single char store it temporarily.
        if (strlen($incrementalOutput) == 1) {
            $this->tmpChar[$project->getName()] = $incrementalOutput;
            // Clear the current incremental output value so that nothing will be written to the console.
            $incrementalOutput = '';
        }
    }
private function workaroundForSingleChar ( string & $ incrementalOutput , Project $ project ) { // Check if there is a temporarily stored char. if ( ! empty ( $ this -> tmpChar [ $ project -> getName ( ) ] ) && ! empty ( $ incrementalOutput ) ) { // Add the char directly at the beginning of the current // incremental output value. $ incrementalOutput = $ this -> tmpChar [ $ project -> getName ( ) ] . $ incrementalOutput ; // Clear the temporarily stored char. $ this -> tmpChar [ $ project -> getName ( ) ] = '' ; } // If there is a single char store it temporarily. if ( strlen ( $ incrementalOutput ) == 1 ) { $ this -> tmpChar [ $ project -> getName ( ) ] = $ incrementalOutput ; // Clear the current incremental output value so that nothing will be written to the console. $ incrementalOutput = '' ; } }
Workaround for single char.

Sometimes it happens that only one char has been returned by $process->getIncrementalOutput()
even if there are more chars that could also be returned.
In this case we need to create a workaround, that temporarily stores
the single char returned to output it in front of the next
incremental output value.

@param string $incrementalOutput
@param Project $project
Workaround for single char .