feat(web-search): add support for Brave search engine (#11106)

This commit is contained in:
Sibs 2022-10-14 20:07:26 +03:00 committed by GitHub
parent b9be3a43b4
commit 52e848ce8f
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 20 additions and 17 deletions

View file

@ -25,9 +25,10 @@ $ google oh-my-zsh
Available search contexts are: Available search contexts are:
| Context | URL | | Context | URL |
|-----------------------|------------------------------------------| | --------------------- | ---------------------------------------- |
| `bing` | `https://www.bing.com/search?q=` | | `bing` | `https://www.bing.com/search?q=` |
| `google` | `https://www.google.com/search?q=` | | `google` | `https://www.google.com/search?q=` |
| `brs` or `brave` | `https://search.brave.com/search?q=` |
| `yahoo` | `https://search.yahoo.com/search?p=` | | `yahoo` | `https://search.yahoo.com/search?p=` |
| `ddg` or `duckduckgo` | `https://www.duckduckgo.com/?q=` | | `ddg` or `duckduckgo` | `https://www.duckduckgo.com/?q=` |
| `sp` or `startpage` | `https://www.startpage.com/do/search?q=` | | `sp` or `startpage` | `https://www.startpage.com/do/search?q=` |

View file

@ -9,6 +9,7 @@ function web_search() {
$ZSH_WEB_SEARCH_ENGINES $ZSH_WEB_SEARCH_ENGINES
google "https://www.google.com/search?q=" google "https://www.google.com/search?q="
bing "https://www.bing.com/search?q=" bing "https://www.bing.com/search?q="
brave "https://search.brave.com/search?q="
yahoo "https://search.yahoo.com/search?p=" yahoo "https://search.yahoo.com/search?p="
duckduckgo "https://www.duckduckgo.com/?q=" duckduckgo "https://www.duckduckgo.com/?q="
startpage "https://www.startpage.com/do/search?q=" startpage "https://www.startpage.com/do/search?q="
@ -47,6 +48,7 @@ function web_search() {
alias bing='web_search bing' alias bing='web_search bing'
alias brs='web_search brave'
alias google='web_search google' alias google='web_search google'
alias yahoo='web_search yahoo' alias yahoo='web_search yahoo'
alias ddg='web_search duckduckgo' alias ddg='web_search duckduckgo'