File tree Expand file tree Collapse file tree 4 files changed +14
-10
lines changed
src/Symfony/Component/Console Expand file tree Collapse file tree 4 files changed +14
-10
lines changed Original file line number Diff line number Diff line change @@ -284,6 +284,19 @@ public function setCode($code)
284
284
public function mergeApplicationDefinition ($ mergeArgs = true )
285
285
{
286
286
if (null === $ this ->application || (true === $ this ->applicationDefinitionMerged && ($ this ->applicationDefinitionMergedWithArgs || !$ mergeArgs ))) {
287
+ if (!$ mergeArgs && $ this ->applicationDefinitionMergedWithArgs ) {
288
+ $ commandArgs = array_udiff (
289
+ $ this ->definition ->getArguments (),
290
+ $ this ->application ->getDefinition ()->getArguments (),
291
+ function ($ arg1 , $ arg2 ) {
292
+ return strcmp ($ arg1 ->getName (), $ arg2 ->getName ());
293
+ }
294
+ );
295
+
296
+ $ this ->definition ->setArguments ($ commandArgs );
297
+ $ this ->applicationDefinitionMergedWithArgs = false ;
298
+ }
299
+
287
300
return ;
288
301
}
289
302
Original file line number Diff line number Diff line change 2
2
help [--xml] [--format="..."] [--raw] [command_name]
3
3
4
4
Arguments:
5
- command The command to execute
6
5
command_name The command name (default: "help")
7
6
8
7
Options:
Original file line number Diff line number Diff line change 2
2
namespace:name
3
3
4
4
<comment>Aliases:</comment> <info>name</info>
5
- <comment>Arguments:</comment>
6
- <info>command </info> The command to execute
7
-
8
5
<comment>Options:</comment>
9
6
<info>--help</info> (-h) Display this help message.
10
7
<info>--quiet</info> (-q) Do not output any message.
Original file line number Diff line number Diff line change 6
6
<aliases>
7
7
<alias>name</alias>
8
8
</aliases>
9
- <arguments>
10
- <argument name="command" is_required="1" is_array="0">
11
- <description>The command to execute</description>
12
- <defaults/>
13
- </argument>
14
- </arguments>
9
+ <arguments/>
15
10
<options>
16
11
<option name="--help" shortcut="-h" accept_value="0" is_value_required="0" is_multiple="0">
17
12
<description>Display this help message.</description>
You can’t perform that action at this time.
0 commit comments