protected function appendMessageToFile($fileFullname, $messages)
    {
        $content = $this->getFileContent($fileFullname);
        $index = $this->getCursorPosition($content);
        $baseFile = basename($fileFullname);

        if ($index === false) {
            throw new Exception('Could not find a position in the [' . $baseFile . '] file to insert the messages.');
        }

        $newContent = substr_replace($content, PHP_EOL . $messages, $index + 1, 1);

        $this->putContentInFile($fileFullname, $newContent)
            ->info('New messages were added to the [' . $baseFile . '] file');
    }
protected function appendMessageToFile($fileFullname, $messages)
    {
        $content = $this->getFileContent($fileFullname);
        $index = $this->getCursorPosition($content);
        $baseFile = basename($fileFullname);

        if ($index === false) {
            throw new Exception('Could not find a position in the [' . $baseFile . '] file to insert the messages.');
        }

        $newContent = substr_replace($content, PHP_EOL . $messages, $index + 1, 1);

        $this->putContentInFile($fileFullname, $newContent)
            ->info('New messages were added to the [' . $baseFile . '] file');
    }
protected function appendMessageToFile ( $ fileFullname , $ messages ) { $ content = $ this -> getFileContent ( $ fileFullname ) ; $ index = $ this -> getCursorPosition ( $ content ) ; $ baseFile = basename ( $ fileFullname ) ; if ( $ index === false ) { throw new Exception ( 'Could not find a position in the [' . $ baseFile . '] file to insert the messages.' ) ; } $ newContent = substr_replace ( $ content , PHP_EOL . $ messages , $ index + 1 , 1 ) ; $ this -> putContentInFile ( $ fileFullname , $ newContent ) -> info ( 'New messages were added to the [' . $ baseFile . '] file' ) ; }
Appends message to an existing language's file.

@param string $fileFullname
@param string $messages

@return void
Appends message to an existing language s file .