libredirect / browser_extension

A browser extension that redirects popular sites to alternative privacy friendly frontends
https://libredirect.github.io
GNU General Public License v3.0
3.29k stars 122 forks source link

[Feature Request] Allow search redirects from google to other search engines #928

Closed TheInfamousAlk closed 3 months ago

TheInfamousAlk commented 6 months ago

So some applications (like discord) have a feature that lets you highlight text and right click to "Search with Google". It opens up a new tab with a google search. There's no way in discord or other apps that do this to change the search provider. They just open a custom URL. I use Kagi. It would be nice if libredirect could parse the search phrase from one engine and redirect to another engine to fix this. There are a few options for "Search" in libredirect now, but it doesn't redirect in the way or to the places I would like, with configurable search engines.

IkelAtomig commented 5 months ago

@ManeraKai - Didn't we have Whoogle and Startpage and removed it. Do you remember the reason.

Not to stall this request, just collecting old insights and see if it's applicable or not.

ManeraKai commented 5 months ago

For startpage: https://libredirect.github.io/faq.html#suggest_frontend

IkelAtomig commented 5 months ago

But Startpage extension, doesn't redirect. Wasn't it the point of the extension ?

ManeraKai commented 5 months ago

For search engines, you don't need redirection. You can just have it as the default search engine in your settings. That's what the Startpage extension does I think. The time where you need proper redirection is when you have to redirect to a random instance (SearXNG, etc...). Even if you want to use a single SearXNG instance, you can just right click the address bar and click "Add to search engine" or something, without needing to rely on LibRedirect.

IkelAtomig commented 5 months ago

If so, it wouldn't apply here because Kagi can be add from Search Bar.

TheInfamousAlk commented 5 months ago

For search engines, you don't need redirection. You can just have it as the default search engine in your settings. That's what the Startpage extension does I think. The time where you need proper redirection is when you have to redirect to a random instance (SearXNG, etc...). Even if you want to use a single SearXNG instance, you can just right click the address bar and click "Add to search engine" or something, without needing to rely on LibRedirect.

Normally you'd just search in the search bar, no redirection needed. This use-case is for applications that literally paste in a URL for a different search engine. Like my example above, Discord has a right click menu item when highlighting text "Search with Google". That opens google and searches for the highlighted text. What I'm asking for here is to detect when google (or another search engine) is being used, and take the search terms and put them in my search engine of choice using URL parsing.

I can use my search engine of choice normally, but sometimes I am given a direct link to a bad search engine that I wand redirected to a better one. Another example is "letmegooglethatforyou" (whichever version of that, there are several) forwards to google. I want it to... not do that. There are other applications that also use the "search with google" right click menu option, and they all have no way of changing google to something else. This is why I want this feature.

IkelAtomig commented 5 months ago

I see, you mean to redirect from the apps which force them into Google and such.

TheInfamousAlk commented 5 months ago

Yes. Or any situation in which you'd end up with a google search, such as clicking directly on a link that is a google search, and translating it to a search in another engine.

IkelAtomig commented 5 months ago

So, We have focus only on Google in that case.

TheInfamousAlk commented 5 months ago

Technically, but I'm sure instances of this behavior exist for other things like bing (i.e. searching via the start menu in some versions of windows, etc).

IkelAtomig commented 5 months ago

Yeah, It would be tricky to find out which one is from Start Menu and from the app. Because Start Menu searches are URL which could also be treated as those opened from Browser history too.

ManeraKai commented 3 months ago

Should we setup a whole different service called Google? So anyone who enables normal Search service won't get affected?

IkelAtomig commented 3 months ago

If my memory is right, the author referring g to redirects in apps not the actual search.

And yes, we need this separately. 17 Aug 2024,  by @.***:

Should we setup a whole different service called > Google> ? So anyone who enables normal > Search> service won't get affected?

— Reply to this email directly, > view it on GitHub https://github.com/libredirect/browser_extension/issues/928#issuecomment-2294679064> , or > unsubscribe https://github.com/notifications/unsubscribe-auth/AYJXNKE2PDGSVMB3ZKXAJFDZR3TOZAVCNFSM6AAAAABH5WPU4SVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDEOJUGY3TSMBWGQ> . You are receiving this because you commented.> Message ID: > <libredirect/browser_extension/issues/928/2294679064> @> github> .> com>

TheInfamousAlk commented 3 months ago

Yeah actual apps will create and open a custom google search link (or bing, if windows does it) and open that link in your default browser. The redirect would have to happen in the browser since we can't get these apps to use a different search engine.

ManeraKai commented 3 months ago

Now you can redirect both Google and Bing after enabling the setting.