]> arthur.ath.cx Git - ax-zsh.git/blob - plugins/websearch/websearch.zshrc
New "websearch" plugin
[ax-zsh.git] / plugins / websearch / websearch.zshrc
1 # AX-ZSH: Alex' Modular ZSH Configuration
2 # google.zshrc: Setup functions for using Google in the command line
3
4 # This is an optional plugin.
5 [[ -z "$AXZSH_PLUGIN_CHECK" ]] || return 92
6
7 function duckduckgo {
8         url="https://duckduckgo.com/?q=$@"
9         open_command "$url" || echo "DuckDuckGo: <$url>"
10 }
11 alias ddg='duckduckgo'
12
13 function ecosia {
14         url="https://www.ecosia.org/search?q=$@"
15         open_command "$url" || echo "Ecosia: <$url>"
16 }
17 alias eco='ecosia'
18
19 function google {
20         url="https://www.google.de/search?q=$@"
21         open_command "$url" || echo "Google: <$url>"
22 }
23 alias g0='google'