File tree Expand file tree Collapse file tree 1 file changed +9
-5
lines changed
Expand file tree Collapse file tree 1 file changed +9
-5
lines changed Original file line number Diff line number Diff line change @@ -130,11 +130,15 @@ export class PluginsService implements IPluginsService {
130130 }
131131
132132 public ensureAllDependenciesAreInstalled ( ) : IFuture < void > {
133- let command = "npm install " ;
134- if ( this . $options . ignoreScripts ) {
135- command += "--ignore-scripts" ;
136- }
137- return this . $childProcess . exec ( command , { cwd : this . $projectData . projectDir } ) ;
133+ return ( ( ) => {
134+ if ( ! this . $fs . exists ( path . join ( this . $projectData . projectDir , constants . NODE_MODULES_FOLDER_NAME ) ) . wait ( ) ) {
135+ let command = "npm install " ;
136+ if ( this . $options . ignoreScripts ) {
137+ command += "--ignore-scripts" ;
138+ }
139+ this . $childProcess . exec ( command , { cwd : this . $projectData . projectDir } ) . wait ( ) ;
140+ }
141+ } ) . future < void > ( ) ( ) ;
138142 }
139143
140144 public getAllInstalledPlugins ( ) : IFuture < IPluginData [ ] > {
You can’t perform that action at this time.
0 commit comments