File tree Expand file tree Collapse file tree 1 file changed +11
-2
lines changed Expand file tree Collapse file tree 1 file changed +11
-2
lines changed Original file line number Diff line number Diff line change @@ -71,7 +71,7 @@ protected function listCommands() : void
7171 ' ' . CLI ::style ($ name , ForegroundColor::green) . ' '
7272 // @phpstan-ignore-next-line
7373 . \str_repeat (' ' , $ width - $ lengths [$ name ])
74- . $ command ->getDescription ()
74+ . $ this -> editDescription ( $ command ->getDescription () )
7575 );
7676 }
7777 \ksort ($ groups );
@@ -84,12 +84,21 @@ protected function listCommands() : void
8484 ' ' . CLI ::style ($ name , ForegroundColor::green) . ' '
8585 // @phpstan-ignore-next-line
8686 . \str_repeat (' ' , $ width - $ lengths [$ name ])
87- . $ command ->getDescription ()
87+ . $ this -> editDescription ( $ command ->getDescription () )
8888 );
8989 }
9090 }
9191 }
9292
93+ protected function editDescription (string $ description ) : string
94+ {
95+ $ description = \trim ($ description );
96+ if (!\str_ends_with ($ description , '. ' )) {
97+ $ description .= '. ' ;
98+ }
99+ return $ description ;
100+ }
101+
93102 /**
94103 * @param array<string,Command> $commands
95104 *
You can’t perform that action at this time.
0 commit comments