Skip to content

Commit

Permalink
Fix cannot find chromium on macOS.
Browse files Browse the repository at this point in the history
  • Loading branch information
cweijan committed Mar 4, 2024
1 parent cbbf0d0 commit 7e4ed0b
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions src/service/markdownService.ts
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,8 @@ export class MarkdownService {
"C:\\Program Files (x86)\\Microsoft\\Edge Beta\\Application\\msedge.exe",
"C:\\Program Files (x86)\\Microsoft\\Edge Dev\\Application\\msedge.exe",
join(homedir(), "AppData\\Local\\Microsoft\\Edge SxS\\Application\\msedge.exe"),
"/Applications/Microsoft/Edge.app",
'"/Applications/Google Chrome.app"',
'"/Applications/Microsoft Edge.app"',
"/usr/bin/microsoft-edge",
]

Expand All @@ -81,8 +82,9 @@ export class MarkdownService {
console.debug(`using chrome path is ${chromePath}`)
return chromePath;
} catch (e) {
vscode.window.showErrorMessage("Not chromium found, export fail.")
throw new Error()
const msg="Not chromium found, export fail.";
vscode.window.showErrorMessage(msg)
throw new Error(msg)
}
}

Expand Down

0 comments on commit 7e4ed0b

Please sign in to comment.