Add functions for firefox aw, pkg and aur
This commit is contained in:
parent
1e6fa4afe2
commit
ade57bda1e
1 changed files with 17 additions and 1 deletions
|
@ -114,12 +114,13 @@ bye() {
|
||||||
sudo protonvpn d
|
sudo protonvpn d
|
||||||
}
|
}
|
||||||
|
|
||||||
|
# Use python to make simple calculations, like 'calc 24/8'
|
||||||
calc() {
|
calc() {
|
||||||
# Use python to make simple calculations, like 'calc 24/8'
|
|
||||||
echo -n "$* = "
|
echo -n "$* = "
|
||||||
python -c "print($*)"
|
python -c "print($*)"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
# Open a map with location after using whois
|
||||||
whois-firefox() {
|
whois-firefox() {
|
||||||
mkfifo pipe; cat pipe &
|
mkfifo pipe; cat pipe &
|
||||||
coords=$(whois "$1" | tee pipe | grep geoloc | sed -r 's/^geoloc:\s+//' | sort | uniq)
|
coords=$(whois "$1" | tee pipe | grep geoloc | sed -r 's/^geoloc:\s+//' | sort | uniq)
|
||||||
|
@ -127,3 +128,18 @@ whois-firefox() {
|
||||||
firefox "https://osm.org/search?query=$coords#map=16/$slash_coords"
|
firefox "https://osm.org/search?query=$coords#map=16/$slash_coords"
|
||||||
rm pipe
|
rm pipe
|
||||||
}
|
}
|
||||||
|
|
||||||
|
# Search the Arch Wiki
|
||||||
|
aw() {
|
||||||
|
firefox "https://wiki.archlinux.org/index.php?title=Special%3ASearch&search=$1" &
|
||||||
|
}
|
||||||
|
|
||||||
|
# Search Arch Packages
|
||||||
|
pkg() {
|
||||||
|
firefox "https://www.archlinux.org/packages/?sort=&maintainer=&flagged=&q=$1" &
|
||||||
|
}
|
||||||
|
|
||||||
|
# Search AUR Packages
|
||||||
|
aur() {
|
||||||
|
firefox "https://aur.archlinux.org/packages/?O=0&SeB=nd&outdated=&SB=n&SO=a&PP=50&K=$1" &
|
||||||
|
}
|
||||||
|
|
Loading…
Add table
Reference in a new issue