Do not output formatting tags
This commit is contained in:
parent
6896865bcc
commit
ef5b087b4f
@ -17,6 +17,7 @@ use Symfony\Component\Console\Helper\Helper;
|
|||||||
use Symfony\Component\Console\Input\InputArgument;
|
use Symfony\Component\Console\Input\InputArgument;
|
||||||
use Symfony\Component\Console\Input\InputDefinition;
|
use Symfony\Component\Console\Input\InputDefinition;
|
||||||
use Symfony\Component\Console\Input\InputOption;
|
use Symfony\Component\Console\Input\InputOption;
|
||||||
|
use Symfony\Component\Console\Output\OutputInterface;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Markdown descriptor.
|
* Markdown descriptor.
|
||||||
@ -27,6 +28,27 @@ use Symfony\Component\Console\Input\InputOption;
|
|||||||
*/
|
*/
|
||||||
class MarkdownDescriptor extends Descriptor
|
class MarkdownDescriptor extends Descriptor
|
||||||
{
|
{
|
||||||
|
/**
|
||||||
|
* {@inheritdoc}
|
||||||
|
*/
|
||||||
|
public function describe(OutputInterface $output, $object, array $options = array())
|
||||||
|
{
|
||||||
|
$decorated = $output->isDecorated();
|
||||||
|
$output->setDecorated(false);
|
||||||
|
|
||||||
|
parent::describe($output, $object, $options);
|
||||||
|
|
||||||
|
$output->setDecorated($decorated);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* {@inheritdoc}
|
||||||
|
*/
|
||||||
|
protected function write($content, $decorated = true)
|
||||||
|
{
|
||||||
|
parent::write($content, $decorated);
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* {@inheritdoc}
|
* {@inheritdoc}
|
||||||
*/
|
*/
|
||||||
|
@ -13,15 +13,15 @@ Displays help for a command
|
|||||||
|
|
||||||
* `help [--format FORMAT] [--raw] [--] [<command_name>]`
|
* `help [--format FORMAT] [--raw] [--] [<command_name>]`
|
||||||
|
|
||||||
The <info>help</info> command displays help for a given command:
|
The help command displays help for a given command:
|
||||||
|
|
||||||
<info>php app/console help list</info>
|
php app/console help list
|
||||||
|
|
||||||
You can also output the help in other formats by using the <comment>--format</comment> option:
|
You can also output the help in other formats by using the --format option:
|
||||||
|
|
||||||
<info>php app/console help --format=xml list</info>
|
php app/console help --format=xml list
|
||||||
|
|
||||||
To display the list of available commands, please use the <info>list</info> command.
|
To display the list of available commands, please use the list command.
|
||||||
|
|
||||||
### Arguments
|
### Arguments
|
||||||
|
|
||||||
@ -125,21 +125,21 @@ Lists commands
|
|||||||
|
|
||||||
* `list [--raw] [--format FORMAT] [--] [<namespace>]`
|
* `list [--raw] [--format FORMAT] [--] [<namespace>]`
|
||||||
|
|
||||||
The <info>list</info> command lists all commands:
|
The list command lists all commands:
|
||||||
|
|
||||||
<info>php app/console list</info>
|
php app/console list
|
||||||
|
|
||||||
You can also display the commands for a specific namespace:
|
You can also display the commands for a specific namespace:
|
||||||
|
|
||||||
<info>php app/console list test</info>
|
php app/console list test
|
||||||
|
|
||||||
You can also output the information in other formats by using the <comment>--format</comment> option:
|
You can also output the information in other formats by using the --format option:
|
||||||
|
|
||||||
<info>php app/console list --format=xml</info>
|
php app/console list --format=xml
|
||||||
|
|
||||||
It's also possible to get raw list of commands (useful for embedding command runner):
|
It's also possible to get raw list of commands (useful for embedding command runner):
|
||||||
|
|
||||||
<info>php app/console list --raw</info>
|
php app/console list --raw
|
||||||
|
|
||||||
### Arguments
|
### Arguments
|
||||||
|
|
||||||
|
@ -20,15 +20,15 @@ Displays help for a command
|
|||||||
|
|
||||||
* `help [--format FORMAT] [--raw] [--] [<command_name>]`
|
* `help [--format FORMAT] [--raw] [--] [<command_name>]`
|
||||||
|
|
||||||
The <info>help</info> command displays help for a given command:
|
The help command displays help for a given command:
|
||||||
|
|
||||||
<info>php app/console help list</info>
|
php app/console help list
|
||||||
|
|
||||||
You can also output the help in other formats by using the <comment>--format</comment> option:
|
You can also output the help in other formats by using the --format option:
|
||||||
|
|
||||||
<info>php app/console help --format=xml list</info>
|
php app/console help --format=xml list
|
||||||
|
|
||||||
To display the list of available commands, please use the <info>list</info> command.
|
To display the list of available commands, please use the list command.
|
||||||
|
|
||||||
### Arguments
|
### Arguments
|
||||||
|
|
||||||
@ -132,21 +132,21 @@ Lists commands
|
|||||||
|
|
||||||
* `list [--raw] [--format FORMAT] [--] [<namespace>]`
|
* `list [--raw] [--format FORMAT] [--] [<namespace>]`
|
||||||
|
|
||||||
The <info>list</info> command lists all commands:
|
The list command lists all commands:
|
||||||
|
|
||||||
<info>php app/console list</info>
|
php app/console list
|
||||||
|
|
||||||
You can also display the commands for a specific namespace:
|
You can also display the commands for a specific namespace:
|
||||||
|
|
||||||
<info>php app/console list test</info>
|
php app/console list test
|
||||||
|
|
||||||
You can also output the information in other formats by using the <comment>--format</comment> option:
|
You can also output the information in other formats by using the --format option:
|
||||||
|
|
||||||
<info>php app/console list --format=xml</info>
|
php app/console list --format=xml
|
||||||
|
|
||||||
It's also possible to get raw list of commands (useful for embedding command runner):
|
It's also possible to get raw list of commands (useful for embedding command runner):
|
||||||
|
|
||||||
<info>php app/console list --raw</info>
|
php app/console list --raw
|
||||||
|
|
||||||
### Arguments
|
### Arguments
|
||||||
|
|
||||||
|
@ -17,15 +17,15 @@ Displays help for a command
|
|||||||
|
|
||||||
* `help [--format FORMAT] [--raw] [--] [<command_name>]`
|
* `help [--format FORMAT] [--raw] [--] [<command_name>]`
|
||||||
|
|
||||||
The <info>help</info> command displays help for a given command:
|
The help command displays help for a given command:
|
||||||
|
|
||||||
<info>php app/console help list</info>
|
php app/console help list
|
||||||
|
|
||||||
You can also output the help in other formats by using the <comment>--format</comment> option:
|
You can also output the help in other formats by using the --format option:
|
||||||
|
|
||||||
<info>php app/console help --format=xml list</info>
|
php app/console help --format=xml list
|
||||||
|
|
||||||
To display the list of available commands, please use the <info>list</info> command.
|
To display the list of available commands, please use the list command.
|
||||||
|
|
||||||
### Arguments
|
### Arguments
|
||||||
|
|
||||||
@ -129,21 +129,21 @@ Lists commands
|
|||||||
|
|
||||||
* `list [--raw] [--format FORMAT] [--] [<namespace>]`
|
* `list [--raw] [--format FORMAT] [--] [<namespace>]`
|
||||||
|
|
||||||
The <info>list</info> command lists all commands:
|
The list command lists all commands:
|
||||||
|
|
||||||
<info>php app/console list</info>
|
php app/console list
|
||||||
|
|
||||||
You can also display the commands for a specific namespace:
|
You can also display the commands for a specific namespace:
|
||||||
|
|
||||||
<info>php app/console list test</info>
|
php app/console list test
|
||||||
|
|
||||||
You can also output the information in other formats by using the <comment>--format</comment> option:
|
You can also output the information in other formats by using the --format option:
|
||||||
|
|
||||||
<info>php app/console list --format=xml</info>
|
php app/console list --format=xml
|
||||||
|
|
||||||
It's also possible to get raw list of commands (useful for embedding command runner):
|
It's also possible to get raw list of commands (useful for embedding command runner):
|
||||||
|
|
||||||
<info>php app/console list --raw</info>
|
php app/console list --raw
|
||||||
|
|
||||||
### Arguments
|
### Arguments
|
||||||
|
|
||||||
|
@ -4,4 +4,4 @@ argument description
|
|||||||
|
|
||||||
* Is required: no
|
* Is required: no
|
||||||
* Is array: no
|
* Is array: no
|
||||||
* Default: `'<comment>style</>'`
|
* Default: `'style'`
|
||||||
|
@ -5,4 +5,4 @@ option description
|
|||||||
* Accept value: yes
|
* Accept value: yes
|
||||||
* Is value required: yes
|
* Is value required: yes
|
||||||
* Is multiple: no
|
* Is multiple: no
|
||||||
* Default: `'<comment>style</>'`
|
* Default: `'style'`
|
||||||
|
@ -5,4 +5,4 @@ option description
|
|||||||
* Accept value: yes
|
* Accept value: yes
|
||||||
* Is value required: yes
|
* Is value required: yes
|
||||||
* Is multiple: yes
|
* Is multiple: yes
|
||||||
* Default: `array ( 0 => '<comment>Hello</comment>', 1 => '<info>world</info>',)`
|
* Default: `array ( 0 => 'Hello', 1 => 'world',)`
|
||||||
|
Reference in New Issue
Block a user