File tree Expand file tree Collapse file tree 2 files changed +10
-3
lines changed Expand file tree Collapse file tree 2 files changed +10
-3
lines changed Original file line number Diff line number Diff line change @@ -550,7 +550,7 @@ module.exports = class RepositoryGenerator extends ArtifactGenerator {
550
550
) ;
551
551
552
552
this . artifactInfo . name = this . artifactInfo . modelNameList
553
- ? this . artifactInfo . modelNameList . join ( )
553
+ ? this . artifactInfo . modelNameList . join ( this . classNameSeparator )
554
554
: this . artifactInfo . modelName ;
555
555
556
556
await super . end ( ) ;
Original file line number Diff line number Diff line change @@ -15,6 +15,8 @@ module.exports = class ArtifactGenerator extends BaseGenerator {
15
15
// Note: arguments and options should be defined in the constructor.
16
16
constructor ( args , opts ) {
17
17
super ( args , opts ) ;
18
+ // how classes are separated when the output contains more than one
19
+ this . classNameSeparator = ', ' ;
18
20
}
19
21
20
22
_setupGenerator ( ) {
@@ -131,12 +133,17 @@ module.exports = class ArtifactGenerator extends BaseGenerator {
131
133
if ( generationStatus ) {
132
134
await this . _updateIndexFiles ( ) ;
133
135
136
+ const classes = this . artifactInfo . name
137
+ . split ( this . classNameSeparator )
138
+ . map ( utils . toClassName ) ;
139
+ const classesOutput = classes . join ( this . classNameSeparator ) ;
140
+
134
141
// User Output
135
142
this . log ( ) ;
136
143
this . log (
137
144
utils . toClassName ( this . artifactInfo . type ) ,
138
- chalk . yellow ( utils . toClassName ( this . artifactInfo . name ) ) ,
139
- 'was created in' ,
145
+ chalk . yellow ( classesOutput ) ,
146
+ classes . length > 1 ? 'were created in' : 'was created in' ,
140
147
`${ this . artifactInfo . relPath } /` ,
141
148
) ;
142
149
this . log ( ) ;
You can’t perform that action at this time.
0 commit comments