File tree Expand file tree Collapse file tree 1 file changed +7
-8
lines changed
Expand file tree Collapse file tree 1 file changed +7
-8
lines changed Original file line number Diff line number Diff line change @@ -65,7 +65,7 @@ if (!packageConfig && !doprConfig) {
6565}
6666
6767// Backward compat.
68- if ( typeof packageConfig . file === 'string' ) {
68+ if ( packageConfig && typeof packageConfig . file === 'string' ) {
6969 packageConfig . file = [ packageConfig . file ] ;
7070}
7171if ( doprConfig && typeof doprConfig . file === 'string' ) {
@@ -172,17 +172,16 @@ cliAction.command.forEach(command => {
172172 return exitHandler ( spawnSync ( 'dopr ' , refArgs , cliOptions ) . status ) ;
173173 }
174174
175+ // Parse command
176+ const cliCommand = command
177+ . replace ( / % a c t i o n % / g, action || '' )
178+ . replace ( / % a r g s % / g, args . join ( ' ' ) ) ;
179+
175180 // Command is expected to run in host context!
176181 if ( cliAction . service === '@host' ) {
177- return execSync ( command , cliOptions ) ;
182+ return execSync ( cliCommand , cliOptions ) ;
178183 }
179184
180- // Parse command
181- const cliCommand = command
182- . replace ( '%action%' , action || '' )
183- . replace ( '%args%' , args . join ( ' ' ) )
184- . split ( ' ' ) ;
185-
186185 // Args
187186 const user = cliAction . user ? [ '--user' , cliAction . user ] : [ ] ;
188187
You can’t perform that action at this time.
0 commit comments