-
Notifications
You must be signed in to change notification settings - Fork 3.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
URLs open in Google Chrome instead of the user's preferred browser #24125
Comments
That's definitely weird. Under the hood we're just passing the request to open the URL to DBUS But I don't know why our request and other Could you make sure that you get the same results when running the following commands?
I've personally had problems in the past where installing a new browser (specifically chrome) would set itself as the default handler in xdg for a bunch of stuff even when I didn't have it set as my default browser and am wondering if that's what's happening here |
I believe xdg-open and dbus are two independent system for default applications. |
I don't believe this is true. DBUS is just the protocol for IPC that we are using to pass the openURI request to the XDG Desktop portal |
@probably-neb the
|
Did you happen to run those commands in the Zed terminal? If not could you do so? This may be a $PATH issue |
@probably-neb all the xdg-* commands and
The |
We've had more than a few issues with $PATH unfortunately. I was wondering if maybe this was one of those and the xdg-portal was pulling the wrong thing due to the incorrect path but it doesn't seem like that's it. The only other thing I can think to do is make sure the desktop portal settings are in order (usually in Unfortunately if you can't find anything in the places I listed above or anywhere else I'm going to close this issue because as far as I can tell there isn't much we can do given that we just pass the open URI request to the XDG portal. Feel free to open up a new discussion proposing the ability to directly set which browser links are opened in from within Zed, I believe that's possible with the DBUS api. We will allocate engineering resources towards the issue based on demand, surface area, complexity, etc. But I'm sure other people would love the ability to control which browser zed uses explicitly as well, so I think there's a pretty good chance we'd do this at some point. |
Ok, I solved the problem. Following this discussion, I could pinpoint the However, it's weird that setting mime handlers in Anyway, as suggested, I'm gonna open a new discussion proposing the ability to set a preferred browser directly in Zed. |
Summary
Zed defaults to opening URLs in Google Chrome instead of using the user's preferred browser and it doesn't seem to be a way of changing that.
Steps to trigger the problem:
Actual Behavior:
Zed opens URL in Google Chrome, which is not the user's preferred web browser.
Expected Behavior:
Zed should open the URL in the user's preferred web browser. It seems that Zed fails to recognize the user's preferred browser. Both
xdg-open <url>
andexo-open --launch WebBrowser <url>
open the URL in Brave, which is my preferred web browser.There is also no way of setting a preferred web browser to open URLs in Zed's settings.
Zed Version and System Specs
Zed: v0.171.6 (Zed)
OS: Linux X11 arcolinux unknown
Memory: 15.5 GiB
Architecture: x86_64
GPU: Intel(R) HD Graphics 530 (SKL GT2) || Intel open-source Mesa driver || Mesa 24.3.4-arch1.1
The text was updated successfully, but these errors were encountered: