reducing repetitive calls
This commit is contained in:
parent
86b51fc94f
commit
82b155ce80
1 changed files with 5 additions and 3 deletions
8
bashrc
8
bashrc
|
@ -16,14 +16,16 @@ dfa() {
|
|||
}
|
||||
vpn() {
|
||||
if [ "$1" == "on" ]; then
|
||||
doas protonvpn c --p2p
|
||||
cmd="c --p2p"
|
||||
elif [ "$1" == "off" ]; then
|
||||
doas protonvpn d
|
||||
cmd="d"
|
||||
elif [ "$1" == "status" ]; then
|
||||
doas protonvpn s
|
||||
cmd="s"
|
||||
else
|
||||
echo "Please pass an argument: on, off, status"
|
||||
return
|
||||
fi
|
||||
doas protonvpn "$cmd"
|
||||
}
|
||||
ip_check() {
|
||||
curl wgetip.net/n
|
||||
|
|
Loading…
Reference in a new issue