File tree Expand file tree Collapse file tree 1 file changed +9
-1
lines changed Expand file tree Collapse file tree 1 file changed +9
-1
lines changed Original file line number Diff line number Diff line change @@ -83,6 +83,8 @@ export const installExtensions = async (libraries: string[]) => {
83
83
throw new Error ( 'Failed to get VSCode path' ) ;
84
84
}
85
85
86
+ vsCodeCliCommandPath = './code' ;
87
+
86
88
cwd = path . join (
87
89
path . resolve ( vsCodeFolderOutput . stdout . trim ( ) ) ,
88
90
'Contents' ,
@@ -100,18 +102,24 @@ export const installExtensions = async (libraries: string[]) => {
100
102
}
101
103
102
104
await new Promise < void > ( ( resolve , reject ) => {
105
+ let output = '' ;
106
+
103
107
const spawner = spawn ( vsCodeCliCommandPath , [ ...extensionsCmdArgs , '--force' ] . flat ( ) , {
104
108
cwd,
105
109
windowsHide : true ,
106
110
shell : true ,
107
111
} ) ;
108
112
113
+ spawner . stderr ?. on ( 'data' , ( data ) => {
114
+ output += data ;
115
+ } ) ;
116
+
109
117
spawner . on ( 'close' , ( exitCode : number ) => {
110
118
if ( exitCode === 0 ) {
111
119
return resolve ( ) ;
112
120
}
113
121
114
- reject ( ) ;
122
+ reject ( output ) ;
115
123
} ) ;
116
124
} ) ;
117
125
} ;
You can’t perform that action at this time.
0 commit comments