@@ -23,7 +23,7 @@ export async function activate(context: ExtensionContext) {
2323 let binaryPath = context . asAbsolutePath ( join ( `install-locator-${ process . platform } ` , 'bin' , 'install-locator' ) ) ;
2424 const javaPath = context . asAbsolutePath ( join ( `install-locator-${ process . platform } ` , 'bin' , 'java' ) ) ;
2525
26- const versions = await new Promise < ProcessingVersion [ ] > ( ( resolve , reject ) => {
26+ await new Promise < void > ( ( resolve , reject ) => {
2727 // add executable permissions to the binary
2828 if ( process . platform !== "win32" ) {
2929 exec ( `chmod +x ${ binaryPath } ` , ( error , stdout , stderr ) => {
@@ -35,6 +35,7 @@ export async function activate(context: ExtensionContext) {
3535 console . error ( `stderr: ${ stderr } ` ) ;
3636 reject ( stderr ) ;
3737 }
38+ resolve ( ) ;
3839 } ) ;
3940
4041 // add executable permissions to the java binary
@@ -47,15 +48,15 @@ export async function activate(context: ExtensionContext) {
4748 console . error ( `stderr: ${ stderr } ` ) ;
4849 reject ( stderr ) ;
4950 }
51+ resolve ( ) ;
5052 } ) ;
5153 } else {
5254 // on windows we need to add the .bat to the binary path
5355 binaryPath = `${ binaryPath } .bat` ;
5456 }
57+ } ) ;
5558
56-
57-
58-
59+ const versions = await new Promise < ProcessingVersion [ ] > ( ( resolve , reject ) => {
5960 exec ( binaryPath , ( error , stdout , stderr ) => {
6061 if ( error ) {
6162 console . error ( `exec error: ${ error } ` ) ;
0 commit comments