File tree Expand file tree Collapse file tree 1 file changed +5
-2
lines changed
packages/angular/cli/models Expand file tree Collapse file tree 1 file changed +5
-2
lines changed Original file line number Diff line number Diff line change @@ -85,12 +85,15 @@ export abstract class Command<T extends BaseCommandOptions = BaseCommandOptions>
85
85
const args = options . filter ( opt => opt . positional !== undefined ) ;
86
86
const opts = options . filter ( opt => opt . positional === undefined ) ;
87
87
88
+ const formatDescription = ( description : string ) =>
89
+ ` ${ description . replace ( / \n / g, '\n ' ) } ` ;
90
+
88
91
if ( args . length > 0 ) {
89
92
this . logger . info ( `arguments:` ) ;
90
93
args . forEach ( o => {
91
94
this . logger . info ( ` ${ terminal . cyan ( o . name ) } ` ) ;
92
95
if ( o . description ) {
93
- this . logger . info ( ` ${ o . description } ` ) ;
96
+ this . logger . info ( formatDescription ( o . description ) ) ;
94
97
}
95
98
} ) ;
96
99
}
@@ -108,7 +111,7 @@ export abstract class Command<T extends BaseCommandOptions = BaseCommandOptions>
108
111
: '' ;
109
112
this . logger . info ( ` ${ terminal . cyan ( '--' + strings . dasherize ( o . name ) ) } ${ aliases } ` ) ;
110
113
if ( o . description ) {
111
- this . logger . info ( ` ${ o . description } ` ) ;
114
+ this . logger . info ( formatDescription ( o . description ) ) ;
112
115
}
113
116
} ) ;
114
117
}
You can’t perform that action at this time.
0 commit comments