add Brave Browser to MacOS and Windows
This commit is contained in:
@@ -48,10 +48,10 @@ def find_flatpak_browser():
|
||||
def find_browser():
|
||||
# find a chromium-based browser on the system to use.
|
||||
if platform.system() == "Windows":
|
||||
# prefers Microsoft Edge on Windows
|
||||
cmds = (
|
||||
"Microsoft/Edge/Application/msedge.exe",
|
||||
"Google/Chrome/Application/chrome.exe",
|
||||
"BraveSoftware/Brave-Browser/Application/brave.exe",
|
||||
"Microsoft/Edge/Application/msedge.exe",
|
||||
)
|
||||
path_elements = map(Path, (environ["ProgramFiles"], environ["ProgramFiles(x86)"]))
|
||||
|
||||
@@ -62,7 +62,12 @@ def find_browser():
|
||||
|
||||
elif platform.system() == "Darwin":
|
||||
# also prefers Google Chrome on MacOS due to popularity of the browser
|
||||
cmds = ("Contents/MacOS/Google Chrome", "Contents/MacOS/Microsoft Edge")
|
||||
cmds = (
|
||||
"Contents/MacOS/Google Chrome",
|
||||
"Contents/MacOS/Microsoft Edge",
|
||||
"Contents/MacOS/Brave Browser",
|
||||
"Contents/MacOS/Chromium",
|
||||
)
|
||||
path_elements = [Path(f"/Applications/{Path(cmd).name}.app") for cmd in cmds]
|
||||
|
||||
# use the first chromium-based browser found as the browser to run Jupyter in app mode
|
||||
|
||||
Reference in New Issue
Block a user