File tree Expand file tree Collapse file tree 1 file changed +5
-1
lines changed
Expand file tree Collapse file tree 1 file changed +5
-1
lines changed Original file line number Diff line number Diff line change 88import path from 'node:path' ;
99import { platform , tmpdir } from 'node:os' ;
1010import fs from 'node:fs' ;
11+ import { execSync } from 'node:child_process' ;
1112import {
1213 Flags ,
1314 loglevel ,
@@ -140,7 +141,10 @@ export class OrgOpenCommand extends SfCommand<OrgOpenOutput> {
140141 flags . path ? decodeURIComponent ( flags . path ) : retUrl
141142 )
142143 ) ;
143- const cp = await utils . openUrl ( `file:///${ tempFilePath } ` , {
144+ const filePathUrl = isWsl
145+ ? 'file:///' + execSync ( `wslpath -m ${ tempFilePath } ` ) . toString ( ) . trim ( )
146+ : `file:///${ tempFilePath } ` ;
147+ const cp = await utils . openUrl ( filePathUrl , {
144148 ...( flags . browser ? { app : { name : apps [ flags . browser ] } } : { } ) ,
145149 ...( flags . private ? { newInstance : platform ( ) === 'darwin' , app : { name : apps . browserPrivate } } : { } ) ,
146150 } ) ;
You can’t perform that action at this time.
0 commit comments