@@ -31,7 +31,7 @@ async function customToolCheck(path: string): Promise<ToolInfo> {
3131 hasTasm : false
3232 } ;
3333 let dir1 = await fs . readDirectory ( uri ) ;
34- console . log ( inArrays ( dir1 , [ "boxasm.bat" , FileType . File ] ) ) ;
34+ // console.log(inArrays(dir1, ["boxasm.bat", FileType.File]));
3535 if ( inArrays ( dir1 , [ "dosbox" , FileType . Directory ] ) && process . platform === "win32" ) {
3636 let dir2 = await fs . readDirectory ( Uri . joinPath ( uri , './dosbox' ) ) ;
3737 if ( inArrays ( dir2 , [ "dosbox.exe" , FileType . File ] ) ) {
@@ -47,7 +47,7 @@ async function customToolCheck(path: string): Promise<ToolInfo> {
4747 info . hasBoxasm = inArrays ( dir1 , [ "boxasm.bat" , FileType . File ] ) ;
4848 info . hasMasm = inArrays ( dir1 , [ "masm" , FileType . Directory ] ) ;
4949 info . hasTasm = inArrays ( dir1 , [ "tasm" , FileType . Directory ] ) ;
50- console . log ( dir1 , info ) ;
50+ // console.log(dir1, info);
5151 return info ;
5252} ;
5353function writefile ( Uri : Uri , Content : string ) {
@@ -82,11 +82,13 @@ export class Config {
8282 this . toolsUri = Uri . joinPath ( content . extensionUri , './tools' ) ;
8383 if ( toolpath ) {
8484 customToolCheck ( toolpath ) . then (
85- ( value ) => { this . customToolInfo = value ; } ,
85+ ( value ) => {
86+ this . customToolInfo = value ;
87+ this . toolsUri = value . uri ;
88+ } ,
8689 ( reason ) => { console . log ( reason ) ; this . customToolInfo = undefined ; }
8790 ) ;
8891 } ;
89-
9092 //写dosbox配置信息
9193 this . writeBoxconfig ( this ) ;
9294 }
0 commit comments